### *** This class provides Binary Compatibility only, not Source Compatibility ***

Package com.sas.services.connection

# Class Credential

java.lang.Object
com.sas.services.connection.Credential

All Implemented Interfaces:
  `Serializable`, `Cloneable`

Direct Known Subclasses:
  `PasswordCredential`, `SecurityPackageCredential`, `TrustedPeerCredential`

@SASScope("ALL") @BinaryCompatibilityOnly public abstract class Credential extends Object implements Cloneable, Serializable
A base class for credentials that can be used to authenticate and authorize use of a connection factory.

See Also:
  - Serialized Form

- ## Constructor Summary

  Constructors
  Modifier
  Constructor
  Description
  `protected`
  `Credential()`
  Construct a credential object.
  `protected`
  `Credential(String domain)`
  Construct a credential object.

- ## Method Summary

  Modifier and Type
  Method
  Description
  `Object`
  `clone()`
  `boolean`
  `equals(Object that)`
  `String`
  `getDomain()`
  Get the authentication domain.
  `Locale`
  `getLocale()`
  Get the locale.
  `int`
  `hashCode()`
  `void`
  `setDomain(String domain)`
  Set the authentication domain.
  `void`
  `setLocale(Locale locale)`
  Set the locale.

  ### Methods inherited from class java.lang.Object

  `finalize, getClass, notify, notifyAll, toString, wait, wait, wait`

- ## Constructor Details

  - ### Credential

    protected Credential(String domain)
    Construct a credential object.
    Parameters:
      `domain` - the authentication domain
    See Also:
      - `setDomain(java.lang.String)`

  - ### Credential

    protected Credential()
    Construct a credential object.

- ## Method Details

  - ### setDomain

    public void setDomain(String domain)
    Set the authentication domain. The domain is a label that the factory uses to group servers and credentials. When connecting through a factory, the factory user must present a credential object with a domain that matches the domain of at least one server managed by the factory.

    Empty string and `null` are considered to be equivalent domains. The default value is empty string.

    Parameters:
      `domain` - the authentication domain

  - ### getDomain

    public String getDomain()
    Get the authentication domain.
    Returns:
      the authentication domain
    See Also:
      - `setDomain(java.lang.String)`

  - ### getLocale

    public Locale getLocale()
    Get the locale.
    Returns:
      the locale

  - ### setLocale

    public void setLocale(Locale locale)
    Set the locale.
    Parameters:
      `locale` - the locale (e.g. en_US)

  - ### equals

    public boolean equals(Object that)
    Overrides:
      `equals` in class `Object`

  - ### hashCode

    public int hashCode()
    Overrides:
      `hashCode` in class `Object`

  - ### clone

    public Object clone()
    Overrides:
      `clone` in class `Object`