org.eclipse.ocl.examples.codegen.analyzer
Class CGUtils

java.lang.Object
  extended by org.eclipse.ocl.examples.codegen.analyzer.CGUtils

public class CGUtils
extends java.lang.Object

Copyright (c) 2013 CEA LIST and others. All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html Contributors: E.D.Willink(CEA LIST) - Initial API and implementation


Constructor Summary
CGUtils()
           
 
Method Summary
static CGParameter createCGParameter(java.lang.String name, CGTypeId typeId)
           
static CGClass getContainingClass(CGElement cgExpression)
           
static boolean isInlinedId(ElementId elementId)
           
static CGValuedElement replace(CGValuedElement oldElement, CGValuedElement newElement)
          Replace oldElement by newElement and return oldElement which is orphaned by the replacement.
static void wrap(CGCallExp wrapExp, CGValuedElement wrappedExp)
          Use wrapExp to wrap wrappedExp.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CGUtils

public CGUtils()
Method Detail

createCGParameter

@NonNull
public static CGParameter createCGParameter(@NonNull
                                                    java.lang.String name,
                                                    @NonNull
                                                    CGTypeId typeId)

getContainingClass

@Nullable
public static CGClass getContainingClass(@NonNull
                                                  CGElement cgExpression)

isInlinedId

public static boolean isInlinedId(@NonNull
                                  ElementId elementId)

replace

@NonNull
public static CGValuedElement replace(@NonNull
                                              CGValuedElement oldElement,
                                              @NonNull
                                              CGValuedElement newElement)
Replace oldElement by newElement and return oldElement which is orphaned by the replacement.


wrap

public static void wrap(@NonNull
                        CGCallExp wrapExp,
                        @NonNull
                        CGValuedElement wrappedExp)
Use wrapExp to wrap wrappedExp.