Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  /*
   * The SmartWeb Framework
   * Copyright (C) 2004-2006
   *
   * This library is free software; you can redistribute it and/or
   * modify it under the terms of the GNU Lesser General Public
   * License as published by the Free Software Foundation; either
   * version 2.1 of the License, or (at your option) any later version.
   *
  * This library is distributed in the hope that it will be useful,
  * but WITHOUT ANY WARRANTY; without even the implied warranty of
  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
  * Lesser General Public License for more details.
  *
  * You should have received a copy of the GNU Lesser General Public
  * License along with this library; if not, write to the Free Software
  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
  *
  * For further informations on the SmartWeb Framework please visit
  *
  *                        http://smartweb.sourceforge.net
  */
 
 package net.smartlab.web.registry;
 
Represents a corporation entity in the registry. This class could be used to store commercial business entities, non-profit organization informations or public corporations like countries or states, eventually through subclassing.

Author(s):
rlogiacco
Hibernate.joined:
subclass schema="registry" table="`corporation`"
Hibernate.joined:
subclass-key column="`id`"
 
 public class Corporation extends Entity {
 
 	private static final long serialVersionUID = 2400674709089161829L;

The main address of the corporation, usually defined as legal situs .

Directed:
true
Uml.property:
name="legalSitus"
Uml.associationEnd:
aggregation="shared" inverse="corporation:net.smartlab.web.registry.MailAddress"
Uml.association:
name="reachable by"
 
 	private MailAddress legalSitus;

Identifing code usually used as unique financial reference to the corporation.
 
 	private String idCode;

Default Constructor
 
 	public Corporation() {
 		super();
 	}

Constructor by idCode

Parameters:
idCode
 
 	public Corporation(String idCode) {
 		super();
 		this. = idCode;
 	}

Constructor using fields

Parameters:
idCode The idCode to be set
legalSitus The legalSitus to be set
 
 	public Corporation(String idCodeMailAddress legalSitus) {
 		super();
 		this. = idCode;
 		setLegalSitus(legalSitus);
 	}

Returns the main address of the corporation, usually defined as legal situs .

Returns:
the main address of the corporation.
Hibernate.many:
to-one column="`legalSitus`" cascade = "all" inverse="true"
Uml.property:
name="legalSitus"
 
	{
		return ;
	}

Setter of the property legalSitus

Parameters:
legalSitus The legalSitus to set.
Uml.property:
name="legalSitus"
	public void setLegalSitus(MailAddress legalSitus
	{
		this. = legalSitus;
	}

Returns the identifing code usually used as unique financial reference to the corporation.

Returns:
returns the identifing code.
Hibernate.property:
column="`idCode`"
	public String getIdCode() {
		return ;
	}

Sets the identifing code usually used as unique financial reference to the corporation.

Parameters:
idCode the identifing code.
	public void setIdCode(String idCode) {
		this. = idCode;
	}

	public boolean equals(Object object) {
		if (!(object instanceof Corporation)) {
			return false;
		}
		Corporation rhs = (Corporationobject;
		return new EqualsBuilder().append(this.getId(), rhs.getId()).append(this.getIdCode(), rhs.getIdCode()).append(this.getLegalSitus(), rhs.getLegalSitus()).isEquals();
	}

	public int hashCode() {
		return new HashCodeBuilder(1816801317, 357614045).append(this.).append(this.).toHashCode();
	}

	public String toString() {
	}
New to GrepCode? Check out our FAQ X