AlternateName (gisgraphy 2.0-final API)
Date: 2010-09-01

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

## com.gisgraphy.domain.geoloc.entity
Class AlternateName

    java.lang.Object
      com.gisgraphy.domain.geoloc.entity.AlternateName

    public class AlternateName

extends java.lang.Object

Represents an Alternate Name of a feature

Author:
  David Masclet

Constructor Summary
`AlternateName()` Default constructor (Needed by CGLib)
`AlternateName(java.lang.String name, AlternateNameSource source)`

Method Summary
`boolean` | `equals(java.lang.Object obj)`
`java.lang.Integer` | `getAlternateNameId()` Returns the alternate name id.
`GisFeature` | `getGisFeature()` The GisFeature, the Alternate name refers to
`java.lang.Long` | `getId()` The datastore id
`java.lang.String` | `getLanguage()`
`java.lang.String` | `getName()`
`AlternateNameSource` | `getSource()` It tells from which files / gazetteers it has been imported
`int` | `hashCode()`
`boolean` | `isPreferredName()` Whether the alternate name is the preferred name for The `GisFeature`
`boolean` | `isShortName()` Whether the alternate name is a short name
`void` | `setAlternateNameId(java.lang.Integer alternateNameId)` Set the alternateName id
`void` | `setGisFeature(GisFeature gisFeature)` Set the gisFeature, the alternate name refers to
`void` | `setId(java.lang.Long id)` Set the datastore id.
`void` | `setLanguage(java.lang.String language)` Set the the iso 639 alpha2 or alpha 3 languageCode for the current alternate name
`void` | `setName(java.lang.String name)` Set the name of the current alternate name
`void` | `setPreferredName(boolean isPreferredName)` Set the alternate name as a preferred name or Not
`void` | `setShortName(boolean isShortName)` Set the Alternate name as a short name or Not
`void` | `setSource(AlternateNameSource source)` Set the source from which the alternate name come from
`java.lang.String` | `toString()`

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

Constructor Detail

### AlternateName

    public AlternateName(java.lang.String name,
                         AlternateNameSource source)

Parameters:
  `name` - The name of the alternate name
  `source` - what is the source the alternate name
See Also:
  `AlternateNameSource`

### AlternateName

    public AlternateName()

  Default constructor (Needed by CGLib)

Method Detail

### getId

    public java.lang.Long getId()

  The datastore id

  Returns:
    The datastore id, it is not a domain value, just a technical One

### setId

    public void setId(java.lang.Long id)

  Set the datastore id. You should never call this method. It is the responsability of the dataStore

  Parameters:
    `id` - The datastore id

### getName

    public java.lang.String getName()

  Returns:
    The name of the current alternate name

### setName

    public void setName(java.lang.String name)

  Set the name of the current alternate name

  Parameters:
    `name` - The name to set

### getGisFeature

    public GisFeature getGisFeature()

  The GisFeature, the Alternate name refers to

  Returns:
    the GisFeature, the AlternateName refers to

### setGisFeature

    public void setGisFeature(GisFeature gisFeature)

  Set the gisFeature, the alternate name refers to

  Parameters:
    `gisFeature` - The GisFeature, the alternate name refers to

### getSource

    public AlternateNameSource getSource()

  It tells from which files / gazetteers it has been imported

  Returns:
    The source from which the Alternate name come From (from the alternate name file, from the dump of the country file, a personal add,...)
  See Also:
    `AlternateNameSource`

### setSource

    public void setSource(AlternateNameSource source)

  Set the source from which the alternate name come from

### getAlternateNameId

    public java.lang.Integer getAlternateNameId()

  Returns the alternate name id. The id could be null if the alternate name come from the country dump file.

  Returns:
    The alternateNameId

### setAlternateNameId

    public void setAlternateNameId(java.lang.Integer alternateNameId)

  Set the alternateName id

  Parameters:
    `alternateNameId` - The id to set

### isPreferredName

    public boolean isPreferredName()

  Whether the alternate name is the preferred name for The `GisFeature`

  Returns:
    true if the alternate name is the preferred name for the `GisFeature`

### setPreferredName

    public void setPreferredName(boolean isPreferredName)

  Set the alternate name as a preferred name or Not

  Parameters:
    `isPreferredName` - The preferred name property

### isShortName

    public boolean isShortName()

  Whether the alternate name is a short name

  Returns:
    true if the Alternate name is a short name

### setShortName

    public void setShortName(boolean isShortName)

  Set the Alternate name as a short name or Not

  Parameters:
    `isShortName` - The short name property

### getLanguage

    public java.lang.String getLanguage()

  Returns:
    The iso639 Alpha2 or alpha 3 LanguageCode of the `AlternateName`

### setLanguage

    public void setLanguage(java.lang.String language)

  Set the the iso 639 alpha2 or alpha 3 languageCode for the current alternate name

  Parameters:
    `language` - The language to set, it will be automaticaly upercased

### hashCode

    public int hashCode()

  Overrides:
    `hashCode` in class `java.lang.Object`

### equals

    public boolean equals(java.lang.Object obj)

  Overrides:
    `equals` in class `java.lang.Object`

### toString

    public java.lang.String toString()

  Overrides:
    `toString` in class `java.lang.Object`

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

Copyright © 2010. All Rights Reserved.