org.alfresco.repo.domain.hibernate
Class DbAuthorityImpl

java.lang.Object
  extended by org.alfresco.repo.domain.hibernate.DbAuthorityImpl
All Implemented Interfaces:
java.io.Serializable, DbAuthority

public class DbAuthorityImpl
extends java.lang.Object
implements DbAuthority, java.io.Serializable

The persisted class for authorities.

See Also:
Serialized Form

Constructor Summary
DbAuthorityImpl()
           
 
Method Summary
 boolean equals(java.lang.Object o)
           
static DbAuthority find(org.hibernate.Session session, java.lang.String authority)
          Helper method to find an authority based on its natural key
 java.lang.String getAuthority()
           
 java.lang.Long getCrc()
          Get the CRC
 java.lang.Long getId()
          Get the object id
 java.lang.Long getVersion()
           
 int hashCode()
           
 void setAuthority(java.lang.String authority)
           
 void setCrc(java.lang.Long crc)
          Use a crc to enforce case sensitive unique key
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

DbAuthorityImpl

public DbAuthorityImpl()
Method Detail

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

hashCode

public int hashCode()
Overrides:
hashCode in class java.lang.Object

getId

public java.lang.Long getId()
Description copied from interface: DbAuthority
Get the object id

Specified by:
getId in interface DbAuthority
Returns:

setCrc

public void setCrc(java.lang.Long crc)
Description copied from interface: DbAuthority
Use a crc to enforce case sensitive unique key

Specified by:
setCrc in interface DbAuthority

getVersion

public java.lang.Long getVersion()
Specified by:
getVersion in interface DbAuthority
Returns:
Returns the version number for optimistic locking

getCrc

public java.lang.Long getCrc()
Description copied from interface: DbAuthority
Get the CRC

Specified by:
getCrc in interface DbAuthority
Returns:

getAuthority

public java.lang.String getAuthority()
Specified by:
getAuthority in interface DbAuthority
Returns:
Returns the authority

setAuthority

public void setAuthority(java.lang.String authority)
Specified by:
setAuthority in interface DbAuthority

find

public static DbAuthority find(org.hibernate.Session session,
                               java.lang.String authority)
Helper method to find an authority based on its natural key

Parameters:
session - the Hibernate session to use
authority - the authority name
Returns:
Returns an existing instance or null if not found


Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.