Package com.uc4.api
Class UC4HostName
- java.lang.Object
-
- com.uc4.api.UC4ObjectName
-
- com.uc4.api.UC4HostName
-
public final class UC4HostName extends UC4ObjectName
This class represents name of an Agent. It contains checks to test if the name is a valid host name.
-
-
Field Summary
-
Fields inherited from class com.uc4.api.UC4ObjectName
maxLength
-
-
Constructor Summary
Constructors Constructor Description UC4HostName(UC4HostName name)
Constructs aUC4HostName
using the specified parameters.UC4HostName(java.lang.String name)
Constructs aUC4HostName
using the specified parameters.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
equals(java.lang.Object obj)
int
hashCode()
boolean
isGenericHost()
Returnstrue
if the name represents a generic group of hosts but not a single host.boolean
isValid(java.lang.String n)
Tests if the supplied name would be a valid name for an object in the Automation Engine.-
Methods inherited from class com.uc4.api.UC4ObjectName
containsVariable, containsVariable, getAllowedChars, getName, isEmpty, toString
-
-
-
-
Constructor Detail
-
UC4HostName
public UC4HostName(java.lang.String name)
Constructs aUC4HostName
using the specified parameters.- Parameters:
name
- Host name- Throws:
InvalidUC4NameException
- if the name is not empty and invalid
-
UC4HostName
public UC4HostName(UC4HostName name)
Constructs aUC4HostName
using the specified parameters.- Parameters:
name
-UC4HostName
-
-
Method Detail
-
isValid
public boolean isValid(java.lang.String n)
Description copied from class:UC4ObjectName
Tests if the supplied name would be a valid name for an object in the Automation Engine. The test is case insensitive.- Overrides:
isValid
in classUC4ObjectName
- Parameters:
n
- Name to be tested- Returns:
- true if this is a valid name of an object
-
isGenericHost
public boolean isGenericHost()
Returnstrue
if the name represents a generic group of hosts but not a single host.- Returns:
- True if the name is a generic host
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classUC4ObjectName
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classUC4ObjectName
-
-