org.kuali.rice.location.impl.state
Class StateBo

java.lang.Object
  extended by org.kuali.rice.krad.bo.BusinessObjectBase
      extended by org.kuali.rice.krad.bo.PersistableBusinessObjectBase
          extended by org.kuali.rice.location.impl.state.StateBo
All Implemented Interfaces:
Serializable, org.apache.ojb.broker.PersistenceBrokerAware, Inactivatable, MutableInactivatable, Coded, GloballyUnique, Versioned, ModelObjectBasic, BusinessObject, ExternalizableBusinessObject, PersistableBusinessObject, StateContract, StateEbo

@Entity
public class StateBo
extends PersistableBusinessObjectBase
implements StateEbo

See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.kuali.rice.krad.bo.PersistableBusinessObjectBase
extension, newCollectionRecord, objectId, versionNumber
 
Constructor Summary
StateBo()
           
 
Method Summary
static StateBo from(State im)
          Converts a immutable object to its mutable counterpart
 String getCode()
          The code value for this object.
 CountryBo getCountry()
           
 String getCountryCode()
          This the postal country code for the State.
 String getName()
          This the postal name for the State.
 boolean isActive()
          The active indicator for an object.
 void setActive(boolean active)
          Sets the record to active or inactive.
 void setCode(String code)
           
 void setCountry(CountryBo country)
           
 void setCountryCode(String countryCode)
           
 void setName(String name)
           
static State to(StateBo bo)
          Converts a mutable bo to its immutable counterpart
 
Methods inherited from class org.kuali.rice.krad.bo.PersistableBusinessObjectBase
afterDelete, afterInsert, afterLookup, afterUpdate, beforeDelete, beforeInsert, beforeUpdate, buildListOfDeletionAwareLists, getExtension, getLegacyDataAdapter, getObjectId, getVersionNumber, isNewCollectionRecord, linkEditableUserFields, postLoad, postPersist, postRemove, postUpdate, prePersist, preRemove, preUpdate, refresh, refreshNonUpdateableReferences, refreshReferenceObject, setExtension, setNewCollectionRecord, setObjectId, setVersionNumber
 
Methods inherited from class org.kuali.rice.krad.bo.BusinessObjectBase
toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.kuali.rice.location.framework.state.StateEbo
getVersionNumber
 
Methods inherited from interface org.kuali.rice.krad.bo.BusinessObject
refresh
 
Methods inherited from interface org.kuali.rice.core.api.mo.ModelObjectBasic
toString
 

Constructor Detail

StateBo

public StateBo()
Method Detail

getCode

public String getCode()
Description copied from interface: StateEbo
The code value for this object. In general a code value cannot be null or a blank string.

Specified by:
getCode in interface Coded
Specified by:
getCode in interface StateEbo
Returns:
the code value for this object.

setCode

public void setCode(String code)

getCountryCode

public String getCountryCode()
Description copied from interface: StateEbo
This the postal country code for the State. This cannot be null or a blank string.

Specified by:
getCountryCode in interface StateContract
Specified by:
getCountryCode in interface StateEbo
Returns:
postal country code

setCountryCode

public void setCountryCode(String countryCode)

getName

public String getName()
Description copied from interface: StateEbo
This the postal name for the State. This cannot be null or a blank string.

Specified by:
getName in interface StateContract
Specified by:
getName in interface StateEbo
Returns:
postal name

setName

public void setName(String name)

isActive

public boolean isActive()
Description copied from interface: StateEbo
The active indicator for an object.

Specified by:
isActive in interface Inactivatable
Specified by:
isActive in interface StateEbo
Returns:
true if active false if not.

setActive

public void setActive(boolean active)
Description copied from interface: StateEbo
Sets the record to active or inactive.

Specified by:
setActive in interface MutableInactivatable
Specified by:
setActive in interface StateEbo

getCountry

public CountryBo getCountry()

setCountry

public void setCountry(CountryBo country)

to

public static State to(StateBo bo)
Converts a mutable bo to its immutable counterpart

Parameters:
bo - the mutable business object
Returns:
An immutable State if the passed in mutable is not null. If the mutable reference was null, then null is returned.

from

public static StateBo from(State im)
Converts a immutable object to its mutable counterpart

Parameters:
im - immutable object
Returns:
a new mutable CountryBo if the passed in immutable is not null. If the immutable reference was null, then null is returned.


Copyright © 2005–2014 The Kuali Foundation. All rights reserved.