/*
 * The contents of this file are subject to the Mozilla Public License Version 1.1
 * (the "License"); you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at <http://www.mozilla.org/MPL/>.
 * 
 * Software distributed under the License is distributed on an "AS IS" basis, WITHOUT
 * WARRANTY OF ANY KIND, either express or implied. See the License for the specific
 * language governing rights and limitations under the License.
 * 
 * The Original Code is the Venice Web Communities System.
 * 
 * The Initial Developer of the Original Code is Eric J. Bowersox <erbo@silcom.com>,
 * for Silverwrist Design Studios.  Portions created by Eric J. Bowersox are
 * Copyright (C) 2001 Eric J. Bowersox/Silverwrist Design Studios.  All Rights Reserved.
 * 
 * Contributor(s): 
 */
package com.silverwrist.venice.core.impl;

import com.silverwrist.venice.core.*;

class UserFoundImpl implements UserFound
{
  /*--------------------------------------------------------------------------------
   * Attributes
   *--------------------------------------------------------------------------------
   */

  private int uid;
  private String name;
  private String description;
  private String given_name;
  private String family_name;
  private String locality;
  private String region;
  private String country;
  private int level = -1;

  /*--------------------------------------------------------------------------------
   * Constructors
   *--------------------------------------------------------------------------------
   */

  UserFoundImpl(int uid, String name, String description, String given_name, String family_name,
		String locality, String region, String country)
  {
    this.uid = uid;
    this.name = name;
    this.description = description;
    this.given_name = given_name;
    this.family_name = family_name;
    this.locality = locality;
    this.region = region;
    this.country = country;

  } // end constructor

  UserFoundImpl(int uid, String name, String description, String given_name, String family_name,
		String locality, String region, String country, int level)
  {
    this.uid = uid;
    this.name = name;
    this.description = description;
    this.given_name = given_name;
    this.family_name = family_name;
    this.locality = locality;
    this.region = region;
    this.country = country;
    this.level = level;

  } // end constructor

  /*--------------------------------------------------------------------------------
   * Implementations from interface UserFound
   *--------------------------------------------------------------------------------
   */

  public int getUID()
  {
    return uid;

  } // end getUID

  public String getName()
  {
    return name;

  } // end getName

  public String getDescription()
  {
    return description;

  } // end getDescription

  public String getGivenName()
  {
    return given_name;

  } // end getGivenName

  public String getFamilyName()
  {
    return family_name;

  } // end getFamilyName

  public String getLocality()
  {
    return locality;

  } // end getLocality

  public String getRegion()
  {
    return region;

  } // end getRegion

  public String getCountry()
  {
    return country;

  } // end getCountry

  public int getLevel()
  {
    return level;

  } // end getLevel

  public UserFound createNewLevel(int level)
  {
    return new UserFoundImpl(this.uid,this.name,this.description,this.given_name,this.family_name,
			     this.locality,this.region,this.country,level);

  } // end createNewLevel

} // end class UserFoundImpl
