Teiid 8.3.0.Final

org.teiid.adminapi.impl
Class ModelMetaData

java.lang.Object
  extended by org.teiid.adminapi.impl.AdminObjectImpl
      extended by org.teiid.adminapi.impl.ModelMetaData
All Implemented Interfaces:
Serializable, AdminObject, Model

public class ModelMetaData
extends AdminObjectImpl
implements Model

See Also:
Serialized Form

Nested Class Summary
static class ModelMetaData.Message
           
 
Nested classes/interfaces inherited from interface org.teiid.adminapi.Model
Model.Type
 
Field Summary
protected  String description
           
protected  List<ModelMetaData.Message> messages
           
protected  String modelType
           
protected  String path
           
protected  List<ModelMetaData.Message> runtimeMessages
           
protected  String schemaSourceType
           
protected  String schemaText
           
protected  LinkedHashMap<String,SourceMappingMetadata> sources
           
protected  Boolean visible
           
 
Fields inherited from class org.teiid.adminapi.impl.AdminObjectImpl
attachments
 
Fields inherited from interface org.teiid.adminapi.AdminObject
DELIMITER, DELIMITER_CHAR, ESCAPED_DELIMITER, ESCAPED_WILDCARD, WILDCARD
 
Constructor Summary
ModelMetaData()
           
 
Method Summary
 ModelMetaData.Message addMessage(ModelMetaData.Message ve)
           
 ModelMetaData.Message addMessage(String severity, String message)
           
 ModelMetaData.Message addRuntimeError(String message)
           
 ModelMetaData.Message addRuntimeMessage(ModelMetaData.Message.Severity severity, String message)
           
 void addSourceMapping(SourceMappingMetadata source)
           
 SourceMappingMetadata addSourceMapping(String name, String translatorName, String connJndiName)
           
 void clearMessages()
           
 void clearRuntimeMessages()
           
 String getDescription()
          Description about the model
 List<ModelMetaData.Message> getMessages()
           
 List<ModelMetaData.Message> getMessages(boolean includeRuntime)
           
 Model.Type getModelType()
          Retrieve the model type.
 String getPath()
           
 String getSchemaSourceType()
           
 String getSchemaText()
           
 String getSourceConnectionJndiName(String sourceName)
          Get the configured JNDI name for the given source name.
 SourceMappingMetadata getSourceMapping(String sourceName)
           
 List<SourceMappingMetadata> getSourceMappings()
           
 List<String> getSourceNames()
          Associated Source Names for the Models
 LinkedHashMap<String,SourceMappingMetadata> getSources()
           
 String getSourceTranslatorName(String sourceName)
          Get the configured translator name for the given source
 List<String> getValidityErrors()
          Shows any validity errors present in the model
 boolean hasErrors()
           
 boolean hasRuntimeMessages()
           
 boolean isSource()
          Determine if this model is a Source model.
 boolean isSupportsMultiSourceBindings()
          Determine whether this model can support more than one source.
 boolean isVisible()
          Determine whether this model is exposed for querying.
 void setDescription(String description)
           
 void setModelType(Model.Type modelType)
           
 void setModelType(String modelType)
           
 void setPath(String path)
           
 void setSchemaSourceType(String schemaSourceType)
           
 void setSchemaText(String schemaText)
           
 void setSourceMappings(List<SourceMappingMetadata> sources)
           
 void setSupportsMultiSourceBindings(boolean supports)
           
 void setVisible(Boolean value)
           
 String toString()
           
 
Methods inherited from class org.teiid.adminapi.impl.AdminObjectImpl
addAttchment, addProperty, getAttachment, getAttachments, getHostName, getName, getProperties, getPropertyValue, getServerGroup, getServerName, removeAttachment, setHostName, setName, setProperties, setServerGroup, setServerName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.teiid.adminapi.AdminObject
getName, getProperties, getPropertyValue
 

Field Detail

sources

protected LinkedHashMap<String,SourceMappingMetadata> sources

modelType

protected String modelType

description

protected String description

path

protected String path

visible

protected Boolean visible

messages

protected List<ModelMetaData.Message> messages

runtimeMessages

protected transient List<ModelMetaData.Message> runtimeMessages

schemaSourceType

protected String schemaSourceType

schemaText

protected String schemaText
Constructor Detail

ModelMetaData

public ModelMetaData()
Method Detail

getDescription

public String getDescription()
Description copied from interface: Model
Description about the model

Specified by:
getDescription in interface Model
Returns:

setDescription

public void setDescription(String description)

isSource

public boolean isSource()
Description copied from interface: Model
Determine if this model is a Source model.

Specified by:
isSource in interface Model
Returns:
true if it contains physical group(s).

isVisible

public boolean isVisible()
Description copied from interface: Model
Determine whether this model is exposed for querying.

Specified by:
isVisible in interface Model
Returns:
true if the model is visible for querying.

getModelType

public Model.Type getModelType()
Description copied from interface: Model
Retrieve the model type.

Specified by:
getModelType in interface Model
Returns:
model type

getPath

public String getPath()

setPath

public void setPath(String path)

isSupportsMultiSourceBindings

public boolean isSupportsMultiSourceBindings()
Description copied from interface: Model
Determine whether this model can support more than one source.

Specified by:
isSupportsMultiSourceBindings in interface Model
Returns:
true if this model supports multiple sources

setSupportsMultiSourceBindings

public void setSupportsMultiSourceBindings(boolean supports)

setModelType

public void setModelType(Model.Type modelType)

setModelType

public void setModelType(String modelType)

toString

public String toString()
Overrides:
toString in class Object

setVisible

public void setVisible(Boolean value)

getSourceMappings

public List<SourceMappingMetadata> getSourceMappings()

getSources

public LinkedHashMap<String,SourceMappingMetadata> getSources()

getSourceMapping

public SourceMappingMetadata getSourceMapping(String sourceName)

setSourceMappings

public void setSourceMappings(List<SourceMappingMetadata> sources)

getSourceNames

public List<String> getSourceNames()
Description copied from interface: Model
Associated Source Names for the Models

Specified by:
getSourceNames in interface Model
Returns:
String

getSourceConnectionJndiName

public String getSourceConnectionJndiName(String sourceName)
Description copied from interface: Model
Get the configured JNDI name for the given source name.

Specified by:
getSourceConnectionJndiName in interface Model
Parameters:
sourceName - - name of the source
Returns:
null if none configured.

getSourceTranslatorName

public String getSourceTranslatorName(String sourceName)
Description copied from interface: Model
Get the configured translator name for the given source

Specified by:
getSourceTranslatorName in interface Model
Returns:

addSourceMapping

public SourceMappingMetadata addSourceMapping(String name,
                                              String translatorName,
                                              String connJndiName)

addSourceMapping

public void addSourceMapping(SourceMappingMetadata source)

hasErrors

public boolean hasErrors()

getMessages

public List<ModelMetaData.Message> getMessages()

getMessages

public List<ModelMetaData.Message> getMessages(boolean includeRuntime)

addMessage

public ModelMetaData.Message addMessage(String severity,
                                        String message)

hasRuntimeMessages

public boolean hasRuntimeMessages()

addRuntimeError

public ModelMetaData.Message addRuntimeError(String message)

addRuntimeMessage

public ModelMetaData.Message addRuntimeMessage(ModelMetaData.Message.Severity severity,
                                               String message)

addMessage

public ModelMetaData.Message addMessage(ModelMetaData.Message ve)

clearRuntimeMessages

public void clearRuntimeMessages()

clearMessages

public void clearMessages()

getSchemaSourceType

public String getSchemaSourceType()

setSchemaSourceType

public void setSchemaSourceType(String schemaSourceType)

getSchemaText

public String getSchemaText()

setSchemaText

public void setSchemaText(String schemaText)

getValidityErrors

public List<String> getValidityErrors()
Description copied from interface: Model
Shows any validity errors present in the model

Specified by:
getValidityErrors in interface Model
Returns:

Teiid 8.3.0.Final

Copyright © 2013 JBoss by Red Hat. All Rights Reserved.