wwndesc  1.0-76
WWNDescription Class Reference

In situations where nicknames simply are not present, but we need descriptors in short-order, the "--wwn=" or "-w" ooption can be used to get a description of what the most likely Nickname would be. More...

Data Structures

class  DemoTestDesc
 test case: this matches a single item known to exist in the Demo Database More...
 

Public Member Functions

WWNDesc getWWNDescriptor (String val)
 Iterates WWNDescription decendents looking for which will accept responsibility, and if so, returns the instance it generates as a descriptor. More...
 
WWNDesc getWWNDescriptor (String val, boolean provideBase)
 Iterates WWNDescription decendents looking for which will accept responsibility, and if so, returns the instance it generates as a descriptor. More...
 
WWNDesc getWWNDescriptor (String val, boolean provideBase, DevRole role)
 Iterates WWNDescription decendents looking for which will accept responsibility, and if so, returns the instance it generates as a descriptor. More...
 
WWNDesc getWWNDescriptor (String val, boolean provideBase, int role)
 Iterates WWNDescription decendents looking for which will accept responsibility, and if so, returns the instance it generates as a descriptor. More...
 
void usage (String proc)
 usage messages are useful to those of us with short memories as well (hey, I just need to add swap!) More...
 

Static Public Member Functions

static void main (String args[])
 Main function, as you can tell. More...
 

Data Fields

boolean briefWWNEstimate = false
 setting to "true" via the "--briefestimate" commandline causes all descriptions later requested in getWWNDescriptor(String) to be "brief" (more concise) More...
 

Detailed Description

In situations where nicknames simply are not present, but we need descriptors in short-order, the "--wwn=" or "-w" ooption can be used to get a description of what the most likely Nickname would be.

For example, "java -jar wwndesc.jar -w 5006048ACCC86A32" results in "Symm-182500953-05bA" matching http://www.emcstorageinfo.com/2007/08/how-to-decode-symmetrix-world-wide.html Note that –briefestimate and –nobriefestimate configure for more brief estimate/suggested nicknames

Examples

java -jar vict.jar –wwn 500610601234567

java -jar vict.jar –briefestimate –wwn 500610601234567

java -jar vict.jar –nobriefestimate –wwn 5000097301234564

Issues

Definition at line 29 of file WWNDescription.java.

Member Function Documentation

WWNDesc getWWNDescriptor ( String  val)
inline

Iterates WWNDescription decendents looking for which will accept responsibility, and if so, returns the instance it generates as a descriptor.

Returns
new instance of WWNDesc descendent, or null if no descendents accept responsibility to describe or provide an alias for that WWN
Parameters
valWWN to check

Definition at line 62 of file WWNDescription.java.

Referenced by WWNDescription.getWWNDescriptor(), and WWNDescription.main().

WWNDesc getWWNDescriptor ( String  val,
boolean  provideBase 
)
inline

Iterates WWNDescription decendents looking for which will accept responsibility, and if so, returns the instance it generates as a descriptor.

Returns
new instance of WWNDesc descendent, or null if no descendents accept responsibility to describe or provide an alias for that WWN
Parameters
valWWN to check
provideBasewhether to provide a bogus WWNDesc instance rather than a null

Definition at line 75 of file WWNDescription.java.

References WWNDescription.getWWNDescriptor().

Here is the call graph for this function:

WWNDesc getWWNDescriptor ( String  val,
boolean  provideBase,
DevRole  role 
)
inline

Iterates WWNDescription decendents looking for which will accept responsibility, and if so, returns the instance it generates as a descriptor.

Returns
new instance of WWNDesc descendent, or null if no descendents accept responsibility to describe or provide an alias for that WWN
Parameters
valWWN to check
provideBasewhether to provide a bogus WWNDesc instance rather than a null
roleDevRole to check for

Definition at line 84 of file WWNDescription.java.

References WWNDescription.getWWNDescriptor(), and DevRole.value.

Here is the call graph for this function:

WWNDesc getWWNDescriptor ( String  val,
boolean  provideBase,
int  role 
)
inline

Iterates WWNDescription decendents looking for which will accept responsibility, and if so, returns the instance it generates as a descriptor.

Returns
new instance of WWNDesc descendent, or null if no descendents accept responsibility to describe or provide an alias for that WWN
Parameters
valWWN to check
provideBasewhether to provide a bogus WWNDesc instance rather than a null
roleDevRole to check for

Definition at line 91 of file WWNDescription.java.

References PureStorageDescription.getDesc(), CiscoSwitchDescription.getDesc(), AIXLPARServerDescription.getDesc(), OraclePillarDescription.getDesc(), HPDotHillDescription.getDesc(), CiscoUCSServerDescription.getDesc(), EMCClariionDescription.getDesc(), EMCVPLEXDescription.getDesc(), HP3ParDescription.getDesc(), EMCSymmetrixDescription.getDesc(), EMCVMAXDescription.getDesc(), NetAppDescription.getDesc(), HDSVSPDescription.getDesc(), IBMDescription.getDesc(), SymbiosDescription.getDesc(), and HPVirtualServerDescription.getDesc().

Here is the call graph for this function:

static void main ( String  args[])
inlinestatic

Main function, as you can tell.

this function merely parses the command-line to dispatch actions to the meat of the meal above. I'm using an actual GetOpt because, yes, I'm a UNIX/C hack, re-using 3-decades-old knowledge, but this also preserves both extensibility and the ability to use longopts in scripts as a way to self-document what the tool's doing.

No real intelligence herein except the parse-and-redirect action.

Parameters
argscommandline arguments passed in by the JRE

Always always ALWAYS provide a quick reference and a version output

Commandline Options:
-H|–help Show a simple help screen as a reminder of options which are understood by the application
Commandline Options:
java -jar wwndesc.jar --help
Commandline Options:
-V|–version Show the current release version for reference
Commandline Options:
java -jar wwndesc.jar --version
1.0-76
Commandline Options:
–briefestimate change to shorter, more brief estimates or descriptions
Commandline Options:
–nobriefestimate change to longer, more detailed estimates (default)
Commandline Options:
-d|–device(=) used mainly in testing, this option allows setting a device type
Commandline Options:
{ init(iator) | server | storage | switch | targ(et) }
Commandline Options:
-p|–port used mainly in testing, this option shows the port-uniqueness of a device (which can be leveraged for de-duping an alias)
Commandline Options:
-w|–wwn query for a description of a WWPN
Commandline Options:
java -jar wwndesc.jar --wwn 5000097201234567
VMax-HK194618641-10fD
Commandline Options:
java -jar wwndesc.jar --briefestimate --wwn 5000097201234567
VMax-18641-10fD

Definition at line 173 of file WWNDescription.java.

References WWNDescription.briefWWNEstimate, WWNDesc.descPort(), WWNDescription.getWWNDescriptor(), WWNDesc.toString(), and WWNDescription.usage().

Here is the call graph for this function:

void usage ( String  proc)
inline

usage messages are useful to those of us with short memories as well (hey, I just need to add swap!)

Parameters
procname of the process or program (ie wwndesc)

Definition at line 145 of file WWNDescription.java.

Referenced by WWNDescription.main().

Field Documentation

boolean briefWWNEstimate = false

setting to "true" via the "--briefestimate" commandline causes all descriptions later requested in getWWNDescriptor(String) to be "brief" (more concise)

See also
WWNDesc::toString()

Definition at line 31 of file WWNDescription.java.

Referenced by WWNDescription.main().


The documentation for this class was generated from the following file: