Package com.uc4.api
Class UC4ObjectName
- java.lang.Object
- 
- com.uc4.api.UC4ObjectName
 
- 
- Direct Known Subclasses:
- UC4HostName,- UC4TimezoneName,- UC4UserName
 
 public class UC4ObjectName extends java.lang.ObjectThis class represents the name of an object in the Automation Engine.
- 
- 
Field SummaryFields Modifier and Type Field Description protected intmaxLength
 - 
Constructor SummaryConstructors Constructor Description UC4ObjectName(UC4ObjectName name)This constructor is required for creating copy of UC4ObjectNameUC4ObjectName(java.lang.String name)Constructs anUC4ObjectNameobject using the specified name.
 - 
Method SummaryAll Methods Instance Methods Concrete Methods Modifier and Type Method Description booleancontainsVariable()booleancontainsVariable(java.lang.String val)Tests if the supplied name is the valid name of a Script Variablebooleanequals(java.lang.Object obj)java.lang.StringgetAllowedChars()Returns the allowed characters of an object namejava.lang.StringgetName()Returns the name or an empty string if the name is not set.inthashCode()booleanisEmpty()Tests if the name is empty.booleanisValid(java.lang.String objectName)Tests if the supplied name would be a valid name for an object in the Automation Engine.java.lang.StringtoString()
 
- 
- 
- 
Constructor Detail- 
UC4ObjectNamepublic UC4ObjectName(java.lang.String name) Constructs anUC4ObjectNameobject using the specified name. Trailing and leading spaces are removed. The parameternameis converted to upper case before the check starts. Ifnameis not a valid object name anInvalidUC4NameExceptionis thrown. An empty string is valid. In this case the methodisEmptyreturnstrue.- Parameters:
- name- name
- Throws:
- InvalidUC4NameException- if the name is not valid
 
 - 
UC4ObjectNamepublic UC4ObjectName(UC4ObjectName name) This constructor is required for creating copy of UC4ObjectName- Parameters:
- name-- UC4ObjectName
 
 
- 
 - 
Method Detail- 
getNamepublic java.lang.String getName() Returns the name or an empty string if the name is not set.- Returns:
- name
 
 - 
isEmptypublic boolean isEmpty() Tests if the name is empty.- Returns:
- trueif the name is an empty string
 
 - 
containsVariablepublic boolean containsVariable() - Returns:
- true if the name contains a Script variable
 
 - 
containsVariablepublic boolean containsVariable(java.lang.String val) Tests if the supplied name is the valid name of a Script Variable- Parameters:
- val- Name to be tested
- Returns:
- true if the name is valid
 
 - 
isValidpublic boolean isValid(java.lang.String objectName) Tests if the supplied name would be a valid name for an object in the Automation Engine. The test is case insensitive.- Parameters:
- objectName- Name to be tested
- Returns:
- true if this is a valid name of an object
 
 - 
toStringpublic java.lang.String toString() - Overrides:
- toStringin class- java.lang.Object
 
 - 
hashCodepublic int hashCode() - Overrides:
- hashCodein class- java.lang.Object
 
 - 
equalspublic boolean equals(java.lang.Object obj) - Overrides:
- equalsin class- java.lang.Object
 
 - 
getAllowedCharspublic java.lang.String getAllowedChars() Returns the allowed characters of an object name- Returns:
- String containing allowed characters. NULL is never returned.
 
 
- 
 
-