|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.sun.comm.Alias
This class is used to faciliate alias wildcarding. Given a Stringname
, this method detects trailing digits. If they exist, the alias is assumed to be a wildcard alias. The base name is seperated from the digits. ThematchesWildcard
method can be used to compare the alias to a user specifiedname
which is presumed to have no digits. It can thus be used to test match for both wildcarded and non-wildcarded aliases.
Field Summary | |
private java.lang.String |
basename
|
private java.lang.String |
original
|
private java.lang.String |
unitNbr
|
Constructor Summary | |
Alias(java.lang.String name)
Sole constructor. |
Method Summary | |
java.lang.String |
appendAliasUnitNbr(java.lang.String wild)
Given a wildcard name, append the digits from the name provided to the constructor. |
java.lang.String |
getBasename()
Get basename stripped of any trailing digits. |
java.lang.String |
getOriginal()
Get original logical name provided to constructor. |
int |
getUnitNbr()
Get the unit number portion of the name initially provided, if any. |
boolean |
matchesWildcard(java.lang.String name)
Determine whether the name provided satisfies a wildcard match of the name provided. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private java.lang.String unitNbr
private java.lang.String basename
private java.lang.String original
Constructor Detail |
public Alias(java.lang.String name)
name
- A logical name to treat as an aliasMethod Detail |
public java.lang.String getOriginal()
public java.lang.String getBasename()
public boolean matchesWildcard(java.lang.String name)
name
- Name to match to this object.
public int getUnitNbr()
public java.lang.String appendAliasUnitNbr(java.lang.String wild)
wild
- Name to have unit number appended to.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |