jreceiver.common.rec.site
Class SiteRec

java.lang.Object
  |
  +--jreceiver.common.rec.BaseRec
        |
        +--jreceiver.common.rec.site.SiteRec
All Implemented Interfaces:
Hashable, Rec, Selectable, Site

public class SiteRec
extends BaseRec
implements Site, Selectable

Bean to describe a record for the Site table

Version:
$Revision: 1.3 $ $Date: 2002/12/29 00:44:08 $
Author:
Reed Esau

Field Summary
protected  java.net.URL content_url
           
protected  boolean is_checked
           
protected  java.lang.String name
           
protected  java.net.URL rpc_url
           
protected  int site_id
           
 
Fields inherited from interface jreceiver.common.rec.site.Site
DEFAULT_HOME_CONTENT_URL, HKEY_SITE_CONTENT_URL, HKEY_SITE_NAME, HKEY_SITE_RPC_URL, SITE_HOME
 
Fields inherited from interface jreceiver.common.rec.Rec
HKEY_KEY, NO_LIMIT
 
Fields inherited from interface jreceiver.common.rec.Selectable
HKEY_CHECKED
 
Constructor Summary
SiteRec(java.util.Hashtable hash)
          ctor - construct from a hashtable, usually retrieved via RPC
SiteRec(int site_id, java.lang.String name, java.net.URL rpc_url, java.net.URL content_url)
          ctor
 
Method Summary
 boolean getChecked()
          get the current select state
 java.net.URL getContentURL()
          obtain the url for the content engine for the site
 java.lang.String getContentUrlStr()
          obtain the url (as a String) for the content engine for the site
 boolean getIsLocal()
          Return true if the site refers to a local file, as indexed in the mfile table.
 boolean getIsRemote()
          return true if the site is offsite, not indexed in the mfile table.
 java.lang.Object getKey()
          return the Integer or Key object that serves as this Rec's key.
 java.lang.String getName()
          obtain the site name (i.e., a local name for someone else's site)
 java.net.URL getRpcURL()
          obtain the url for the RPC engine for the site
 java.lang.String getRpcUrlStr()
          obtain the url (as a String) for the RPC engine for the site
 int getSiteId()
          obtain the site id
 void setChecked(boolean is_checked)
          set the select state
 void setContentURL(java.net.URL content_url)
          assign the url for the content engine for the site
 void setContentUrlStr(java.lang.String s_url)
          assign the url (as a String) for the content engine for the site
 void setKey(java.lang.Object new_key)
          assign the Number-derived, Key-derived or String that serves as this Rec's key.
 void setName(java.lang.String name)
          assign the site name (i.e., a local name for someone else's site)
 void setRpcURL(java.net.URL rpc_url)
          assign the url for the RPC engine for the site
 void setRpcUrlStr(java.lang.String s_url)
          assign the url (as a String) for the RPC engine for the site
 void setSiteId(int site_id)
          assign the site id
 java.util.Hashtable toHash()
          Store the object as a hash suitable for transport over an RPC connection or similar.
 java.lang.String toString()
          Returns a string representation of the object.
 
Methods inherited from class jreceiver.common.rec.BaseRec
dissolve, dissolveMap, find, find, find, find
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

site_id

protected int site_id

name

protected java.lang.String name

rpc_url

protected java.net.URL rpc_url

content_url

protected java.net.URL content_url

is_checked

protected boolean is_checked
Constructor Detail

SiteRec

public SiteRec(int site_id,
               java.lang.String name,
               java.net.URL rpc_url,
               java.net.URL content_url)
ctor

SiteRec

public SiteRec(java.util.Hashtable hash)
        throws RecException
ctor - construct from a hashtable, usually retrieved via RPC
Parameters:
hash -  
Method Detail

toString

public java.lang.String toString()
Description copied from interface: Hashable
Returns a string representation of the object.
Specified by:
toString in interface Hashable
Overrides:
toString in class java.lang.Object

getKey

public java.lang.Object getKey()
return the Integer or Key object that serves as this Rec's key.
Specified by:
getKey in interface Rec

setKey

public void setKey(java.lang.Object new_key)
assign the Number-derived, Key-derived or String that serves as this Rec's key.
Specified by:
setKey in interface Rec

getSiteId

public int getSiteId()
Description copied from interface: Site
obtain the site id
Specified by:
getSiteId in interface Site

setSiteId

public void setSiteId(int site_id)
Description copied from interface: Site
assign the site id
Specified by:
setSiteId in interface Site

getName

public java.lang.String getName()
Description copied from interface: Site
obtain the site name (i.e., a local name for someone else's site)
Specified by:
getName in interface Site

setName

public void setName(java.lang.String name)
Description copied from interface: Site
assign the site name (i.e., a local name for someone else's site)
Specified by:
setName in interface Site

getRpcURL

public java.net.URL getRpcURL()
Description copied from interface: Site
obtain the url for the RPC engine for the site
Specified by:
getRpcURL in interface Site

setRpcURL

public void setRpcURL(java.net.URL rpc_url)
Description copied from interface: Site
assign the url for the RPC engine for the site
Specified by:
setRpcURL in interface Site

getContentURL

public java.net.URL getContentURL()
Description copied from interface: Site
obtain the url for the content engine for the site
Specified by:
getContentURL in interface Site

setContentURL

public void setContentURL(java.net.URL content_url)
Description copied from interface: Site
assign the url for the content engine for the site
Specified by:
setContentURL in interface Site

getRpcUrlStr

public java.lang.String getRpcUrlStr()
Description copied from interface: Site
obtain the url (as a String) for the RPC engine for the site
Specified by:
getRpcUrlStr in interface Site

setRpcUrlStr

public void setRpcUrlStr(java.lang.String s_url)
                  throws java.net.MalformedURLException
Description copied from interface: Site
assign the url (as a String) for the RPC engine for the site
Specified by:
setRpcUrlStr in interface Site

getContentUrlStr

public java.lang.String getContentUrlStr()
Description copied from interface: Site
obtain the url (as a String) for the content engine for the site
Specified by:
getContentUrlStr in interface Site

setContentUrlStr

public void setContentUrlStr(java.lang.String s_url)
                      throws java.net.MalformedURLException
Description copied from interface: Site
assign the url (as a String) for the content engine for the site
Specified by:
setContentUrlStr in interface Site

getIsLocal

public boolean getIsLocal()
Description copied from interface: Site
Return true if the site refers to a local file, as indexed in the mfile table.
Specified by:
getIsLocal in interface Site

getIsRemote

public boolean getIsRemote()
Description copied from interface: Site
return true if the site is offsite, not indexed in the mfile table.
Specified by:
getIsRemote in interface Site

toHash

public java.util.Hashtable toHash()
Store the object as a hash suitable for transport over an RPC connection or similar.

Use SiteRec(Hashtable) to transform the data back into an object of this type.

Specified by:
toHash in interface Hashable
Returns:
 

getChecked

public boolean getChecked()
Description copied from interface: Selectable
get the current select state
Specified by:
getChecked in interface Selectable
Following copied from interface: jreceiver.common.rec.Selectable
Returns:
boolean true if the item has been selected by the user; false otherwise

setChecked

public void setChecked(boolean is_checked)
Description copied from interface: Selectable
set the select state
Specified by:
setChecked in interface Selectable
Following copied from interface: jreceiver.common.rec.Selectable
Parameters:
is_checked -  


Copyright © 2001-2002 Reed Esau, All Rights Reserved.