jsdsi
Class Name

java.lang.Object
  |
  +--jsdsi.Obj
        |
        +--jsdsi.Name
All Implemented Interfaces:
Subject

public class Name
extends Obj
implements Subject

A SDSI name: a principal and a sequence of strings. If the sequence contains just one string, this is a local name; otherwise this is an extended name.

Author:
Sameer Ajmani

Nested Class Summary
 
Nested classes inherited from class jsdsi.Subject
Subject.Default
 
Constructor Summary
Name(Principal i, java.lang.String n)
           
Name(Principal i, java.lang.String[] n)
           
 
Method Summary
 boolean equals(java.lang.Object o)
           
 Principal getIssuer()
           
 java.lang.String[] getNames()
           
 int hashCode()
           
(package private) static Name parseName(SexpList l)
           
(package private) static Name parseName(SexpList l, Principal issuerParam)
           
 Name prefix()
           
 Name prefix(int i)
           
 boolean prefixOf(Name n)
           
 SexpList toSexp()
           
 SexpList toSexp(Principal iss)
           
 
Methods inherited from class jsdsi.Obj
parseObj, parseObj, toByteArray, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

Name

public Name(Principal i,
            java.lang.String[] n)

Name

public Name(Principal i,
            java.lang.String n)
Method Detail

getIssuer

public Principal getIssuer()

getNames

public java.lang.String[] getNames()

prefixOf

public boolean prefixOf(Name n)

prefix

public Name prefix(int i)

prefix

public Name prefix()

equals

public boolean equals(java.lang.Object o)
Specified by:
equals in class Obj

hashCode

public int hashCode()
Specified by:
hashCode in class Obj

toSexp

public SexpList toSexp()
Specified by:
toSexp in interface Subject
Specified by:
toSexp in class Obj

toSexp

public SexpList toSexp(Principal iss)

parseName

static Name parseName(SexpList l)
               throws SexpParseException
SexpParseException

parseName

static Name parseName(SexpList l,
                      Principal issuerParam)
               throws SexpParseException
SexpParseException