Package editor
Class TypeNameValidator
- java.lang.Object
-
- editor.TypeNameValidator
-
- All Implemented Interfaces:
IGosuValidator
public class TypeNameValidator extends java.lang.Object implements IGosuValidator
Checks that the source is the name of a type which is assignable to a given type.
-
-
Field Summary
Fields Modifier and Type Field Description private IType_expectedTypeprivate ITypeUsesMap_typeUsesMap
-
Constructor Summary
Constructors Constructor Description TypeNameValidator(IType expectedType)TypeNameValidator(IType expectedType, ITypeUsesMap typeUsesMap)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description private ITypegetType(java.lang.String name)voidvalidate(IParsedElement rootParsedElement, java.lang.String scriptSrc)Provides additional semantic checks to a Gosu parser
-
-
-
Field Detail
-
_expectedType
private final IType _expectedType
-
_typeUsesMap
private final ITypeUsesMap _typeUsesMap
-
-
Constructor Detail
-
TypeNameValidator
public TypeNameValidator(IType expectedType)
-
TypeNameValidator
public TypeNameValidator(IType expectedType, ITypeUsesMap typeUsesMap)
-
-
Method Detail
-
validate
public void validate(IParsedElement rootParsedElement, java.lang.String scriptSrc)
Description copied from interface:IGosuValidatorProvides additional semantic checks to a Gosu parser- Specified by:
validatein interfaceIGosuValidator- Parameters:
rootParsedElement- - the root parsed element to validate from
-
getType
private IType getType(java.lang.String name)
-
-