org.eclipse.jst.jsf.taglibprocessing.internal.provisional.attributevalues
Class FacesConfigIdentifierFeatures

java.lang.Object
  extended byorg.eclipse.jst.jsf.metadataprocessors.internal.provisional.AbstractMetaDataEnabledFeature
      extended byorg.eclipse.jst.jsf.taglibprocessing.internal.provisional.attributevalues.FacesConfigIdentifierFeatures
All Implemented Interfaces:
IMetaDataEnabledFeature, IPossibleValues, IValidELValues, IValidValues
Direct Known Subclasses:
FacesConfigConverterIDFeatures, FacesConfigValidatorIDFeatures

public abstract class FacesConfigIdentifierFeatures
extends AbstractMetaDataEnabledFeature
implements IPossibleValues, IValidValues, IValidELValues

Abstract meta-data processing feature representing a faces-config type


Field Summary
static java.lang.String ID_TYPE_PROP_NAME
          Meta-data property name to use for identifying the faces-config type
protected  java.lang.String imageName
          Name of image file to use with content assist proposals
protected static org.eclipse.jface.resource.ImageDescriptor MISSING_IMAGE
          Missing image descriptor
protected  java.util.List validationMessages
          Validation messages to return
 
Fields inherited from interface org.eclipse.jst.jsf.metadataprocessors.internal.provisional.features.IPossibleValues
POSSIBLE_VALUES_FOR_DISPLAY_PROP_NAME, POSSIBLE_VALUES_PROP_NAME, POSSIBLE_VALUES_SMALL_ICON_PROP_NAME
 
Fields inherited from interface org.eclipse.jst.jsf.metadataprocessors.internal.provisional.features.IValidValues
VALID_VALUES_CODE_PROP_NAME, VALID_VALUES_MAX_PROP_NAME, VALID_VALUES_MESSAGE_PROP_NAME, VALID_VALUES_MIN_PROP_NAME, VALID_VALUES_PROP_NAME, VALID_VALUES_SEVERITY_PROP_NAME
 
Constructor Summary
FacesConfigIdentifierFeatures()
           
 
Method Summary
protected  PossibleValue createProposal(java.lang.String value, org.eclipse.emf.common.util.EList displayName, org.eclipse.emf.common.util.EList description)
           
protected  int getAssignmentType()
           
protected  java.lang.String getCMValidationCode()
           
protected  java.lang.String getCMValidationMessage()
           
protected  int getCMValidationSeverity()
           
protected abstract  java.util.List getElementIDs(JSFAppConfigManager mgr)
           
protected abstract  java.util.List getElements(JSFAppConfigManager mgr)
           
 org.eclipse.jst.jsf.core.internal.types.CompositeType getExpectedRuntimeType()
           
protected  org.eclipse.jface.resource.ImageDescriptor getImage()
           
protected abstract  java.lang.String getImageName()
           
protected abstract  java.lang.String getMyValidationMessage(java.lang.String value)
           
protected abstract  java.util.List getPossibleValueProposals(java.util.List elements)
           
 java.util.List getPossibleValues()
           
protected abstract  java.lang.String getReturnType()
           
protected  IValidationMessage getValidationMessage(java.lang.String value)
          Creates an IValidationMessage
 java.util.List getValidationMessages()
           
 boolean isValidValue(java.lang.String value)
           
protected  java.lang.String singleQuote(java.lang.String value)
           
 
Methods inherited from class org.eclipse.jst.jsf.metadataprocessors.internal.provisional.AbstractMetaDataEnabledFeature
getBundleID, getCMAnnotationContext, getCMAttributePropertyValue, getCMAttributePropertyValues, getCMSmallIcon, getStructuredDocumentContext, setBundleID, setContentModelContext, setStructuredDocumentContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.eclipse.jst.jsf.metadataprocessors.internal.provisional.IMetaDataEnabledFeature
getBundleID, getCMAnnotationContext, getStructuredDocumentContext, setBundleID, setContentModelContext, setStructuredDocumentContext
 

Field Detail

ID_TYPE_PROP_NAME

public static final java.lang.String ID_TYPE_PROP_NAME
Meta-data property name to use for identifying the faces-config type

See Also:
converterID and validatorID attributes, Constant Field Values

MISSING_IMAGE

protected static final org.eclipse.jface.resource.ImageDescriptor MISSING_IMAGE
Missing image descriptor


imageName

protected java.lang.String imageName
Name of image file to use with content assist proposals


validationMessages

protected java.util.List validationMessages
Validation messages to return

Constructor Detail

FacesConfigIdentifierFeatures

public FacesConfigIdentifierFeatures()
Method Detail

getPossibleValues

public java.util.List getPossibleValues()
Specified by:
getPossibleValues in interface IPossibleValues
Returns:
List of IPossibleValue instances representing possible values Implementer must ensure that an empty rather than null list is returned if no values are posssible.

isValidValue

public boolean isValidValue(java.lang.String value)
Specified by:
isValidValue in interface IValidValues
Returns:
true if is valid

getMyValidationMessage

protected abstract java.lang.String getMyValidationMessage(java.lang.String value)
Returns:
the validation message String

getValidationMessage

protected IValidationMessage getValidationMessage(java.lang.String value)
Creates an IValidationMessage

Parameters:
value -
Returns:
IValidationMessage

singleQuote

protected java.lang.String singleQuote(java.lang.String value)
Parameters:
value -
Returns:
single-quoted value

getValidationMessages

public java.util.List getValidationMessages()
Specified by:
getValidationMessages in interface IValidValues
Returns:
List of IValidationMessage objects if invalid Must return empty list rather than null Call to isValidValue(String value) required before this should be called.

getElements

protected abstract java.util.List getElements(JSFAppConfigManager mgr)
Returns:
list of faces-config element for the specified config-type

getPossibleValueProposals

protected abstract java.util.List getPossibleValueProposals(java.util.List elements)
Parameters:
elements -
Returns:
list of IPossibleValue objects for the specified list of config elements

getImageName

protected abstract java.lang.String getImageName()
Returns:
image name relative to the FacesConfigEditPlugin where the images are stored

getImage

protected org.eclipse.jface.resource.ImageDescriptor getImage()
Overrides:
getImage in class AbstractMetaDataEnabledFeature
Returns:
ImageDescriptor from the small-icon property for annotation from the same bundle as the annotation

createProposal

protected PossibleValue createProposal(java.lang.String value,
                                       org.eclipse.emf.common.util.EList displayName,
                                       org.eclipse.emf.common.util.EList description)
Parameters:
value -
displayName -
description -
Returns:
PossibleValue object

getElementIDs

protected abstract java.util.List getElementIDs(JSFAppConfigManager mgr)
Returns:
list of identifier Strings for config-type

getReturnType

protected abstract java.lang.String getReturnType()
Returns:
the config-type

getAssignmentType

protected int getAssignmentType()

getExpectedRuntimeType

public org.eclipse.jst.jsf.core.internal.types.CompositeType getExpectedRuntimeType()
                                                                             throws ELIsNotValidException
Specified by:
getExpectedRuntimeType in interface IValidELValues
Throws:
ELIsNotValidException

getCMValidationMessage

protected java.lang.String getCMValidationMessage()

getCMValidationSeverity

protected int getCMValidationSeverity()

getCMValidationCode

protected java.lang.String getCMValidationCode()