Aktuell unterstützte Sprachkonstrukte

  • Compilation Unit
  • Namespace
  • Class
  • Interface
  • Enumeration
  • Constructor
  • Operation
  • Delegate
  • Member Variable
  • Property
  • Assignment
  • Procedure Call
  • Delegate Procedure Call
  • Return
  • If
  • Switch
  • For Each
  • Compound Statement
  • New
  • Function Call
  • Delegate Function Call
  • Type Cast
  • Binary Expression
  • Unary Expression
  • Variable Expression

Beispiel von generiertem C# Code

using MetaGenius.IUmm;
using System;
using System.Collections.Generic;
using MetaGenius.Mmpi.Cpp;

namespace MetaGenius.Mmpi.Cpp
{
    /*#######################################################################################################################################################*/
    public class Cpp_Factory
    /*#######################################################################################################################################################*/
    {
        /*---------------------------------------------------------------------------------------------------------------------------------------------------*/
        private IUmmRepository ThisRepository = null;
        
        
        /*---------------------------------------------------------------------------------------------------------------------------------------------------*/
        private IUmmMetaModel ThisMetaModel = null;
        
        
        /*---------------------------------------------------------------------------------------------------------------------------------------------------*/
        public Boolean StandAllone
        /*---------------------------------------------------------------------------------------------------------------------------------------------------*/
        {
            get
            {
                return ( ThisRepository == null );
            }
        }
        
        
        /*---------------------------------------------------------------------------------------------------------------------------------------------------*/
        private delegate Cpp_Base GetProxy( Cpp_Factory  factory,
                                            IUmmInstance actualInstance );
        
        
        /*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*/
        public Cpp_Factory( IUmmRepository repository )
        /*+++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++*/
        {
            if ( repository != null ) 
            {
                ThisMetaModel = (IUmmMetaModel) repository.GetThingByMguid( Cpp_Factory.ThisMetaModelMguid );
                
                ThisRepository = repository;
            }
        }
        
        
        /*===================================================================================================================================================*/
        public Cpp_Model Get_ModelProxy( IUmmModel actualModel )
        /*===================================================================================================================================================*/
        {
            Cpp_Model result = null;
            
            if ( actualModel != null ) 
            {
                if ( !ThisModelDictionary.TryGetValue( actualModel.Mguid,
                                                       out result ) ) 
                {
                    result = new Cpp_Model( actualModel,
                                            this );
                    
                    ThisModelDictionary.Add( actualModel.Mguid,
                                             result );
                }
            }
            
            return result;
        }
    }
}