Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## ix.util
Class NameMapper

    java.lang.Object
      ix.util.NameMapper

Direct Known Subclasses:
  LCNameMapper

    public class NameMapper

extends java.lang.Object

Maps both ways between short and long names.

Field Summary
`(package private) Gensym.Generator` | `gensym`
`protected java.util.Map` | `longToShort`
`protected java.util.Map` | `shortToLong`

Constructor Summary
`NameMapper()`
`NameMapper(java.util.Map shortToLong)`

Method Summary
`java.lang.String` | `generateShortName(java.lang.String longName)`
`java.util.Map` | `getLongToShortMap()`
`java.util.Map` | `getShortToLongMap()`
`boolean` | `hasLongName(java.lang.String shortName)`
`protected boolean` | `hasSeparator(java.lang.String s, int sepChar)`
`boolean` | `hasShortName(java.lang.String longName)`
`java.lang.String` | `longName(java.lang.String shortName)`
`java.lang.String` | `mapLongName(java.lang.Object obj)`
`java.lang.String` | `mapLongName(java.lang.String longName)` Returns a suitable short name for a long name, generating and storing a short name if one is not already in the map.
`java.lang.String` | `plausibleShortName(java.lang.String longName)`
`void` | `setMapping(java.lang.String longName, java.lang.String shortName)`
`java.lang.String` | `shortName(java.lang.String longName)`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### gensym

    Gensym.Generator gensym

### longToShort

    protected java.util.Map longToShort

### shortToLong

    protected java.util.Map shortToLong

Constructor Detail

### NameMapper

    public NameMapper()

### NameMapper

    public NameMapper(java.util.Map shortToLong)

Method Detail

### hasShortName

    public boolean hasShortName(java.lang.String longName)

### shortName

    public java.lang.String shortName(java.lang.String longName)

### hasLongName

    public boolean hasLongName(java.lang.String shortName)

### longName

    public java.lang.String longName(java.lang.String shortName)

### getShortToLongMap

    public java.util.Map getShortToLongMap()

### getLongToShortMap

    public java.util.Map getLongToShortMap()

### setMapping

    public void setMapping(java.lang.String longName,
                           java.lang.String shortName)

### mapLongName

    public java.lang.String mapLongName(java.lang.Object obj)

### mapLongName

    public java.lang.String mapLongName(java.lang.String longName)

  Returns a suitable short name for a long name, generating and storing a short name if one is not already in the map.

### generateShortName

    public java.lang.String generateShortName(java.lang.String longName)

### plausibleShortName

    public java.lang.String plausibleShortName(java.lang.String longName)

### hasSeparator

    protected boolean hasSeparator(java.lang.String s,
                                   int sepChar)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD