FileDocCategorySizeDatePackage
ZipCodeTag.javaAPI DocExample1953Wed Aug 23 13:19:50 BST 2006com.oreilly.ajax

ZipCodeTag

public final class ZipCodeTag extends javax.faces.webapp.UIComponentTag

Fields Summary
private String
zipcodeId
private String
stateId
private String
cityId
private String
url
Constructors Summary
Methods Summary
public java.lang.StringgetCityId()


    
  
    return cityId;
  
public java.lang.StringgetComponentType()

    return "oreilly.ajax.ZipCode";
  
public java.lang.StringgetRendererType()

    return "ZipCode"; // ZipCodeRenderer
  
public java.lang.StringgetStateId()

    return stateId;
  
public java.lang.StringgetUrl()

    return url;
  
public java.lang.StringgetZipcodeId()

    return zipcodeId;
  
public voidrelease()

    zipcodeId = null;
    stateId = null;
    cityId = null;
    url = null;
  
public voidsetCityId(java.lang.String city)

    this.cityId = city;
  
protected voidsetProperties(javax.faces.component.UIComponent component)

    super.setProperties(component);
    ZipCode input = null;

    try
    {
      input = (ZipCode) component;
    }
    catch (ClassCastException cce)
    {
      throw new IllegalStateException(
          "Component "
              + component.toString()
              + " not expected type.  Expected: ZipCode.  Perhaps you're missing a tag?");
    }
    FacesContext context = getFacesContext();
    if (cityId != null)
    {
      if (isValueReference(cityId))
      {
        ValueBinding vb = context.getApplication().createValueBinding(cityId);
        component.setValueBinding("cityId", vb);
      }
      else
      {
        input.setCityId(cityId);
      }
    }
  
public voidsetStateId(java.lang.String state)

    this.stateId = state;
  
public voidsetUrl(java.lang.String url)

    this.url = url;
  
public voidsetZipcodeId(java.lang.String zipcodeId)

    this.zipcodeId = zipcodeId;