public class OCLResource
extends XMIResourceImpl
Constructor and Description |
---|
OCLResource(URI uri)
Initializes me with my URI.
|
Modifier and Type | Method and Description |
---|---|
OCLExpression |
getOCLExpression()
Obtains the OCL expression that I store.
|
static String |
load(String path)
Loads an OCL expression from the specified
path . |
void |
setOCLExpression(OCLExpression expr)
Sets my contents to the specified OCL expression.
|
public OCLResource(URI uri)
uri
- my URIpublic static String load(String path) throws IOException
path
. The
OCL expression is converted to a string using a custom AST visitor that
renders the string representation.path
- the absolute path of the XMI file to loadIOException
- if anything goes wrong in loading the XMI filepublic void setOCLExpression(OCLExpression expr)
expr
- an OCL expressionpublic OCLExpression getOCLExpression()
Copyright © 2005, 2018 IBM Corporation and others. All Rights Reserved.