it.geosolutions.geoserver.rest.encoder.authorityurl
Class GSAuthorityURLInfoEncoder

java.lang.Object
  extended by it.geosolutions.geoserver.rest.encoder.utils.XmlElement
      extended by it.geosolutions.geoserver.rest.encoder.authorityurl.GSAuthorityURLInfoEncoder

public class GSAuthorityURLInfoEncoder
extends XmlElement

GSAuthorityURLInfoEncoder - encodes an authorityURL for a given GeoServer layer as follows:

 final GSAuthorityURLInfoEncoder ae = new GSAuthorityURLInfoEncoder();
 ae.setName("an authority");
 ae.setHref("http://www.organization.org");
 
 
For this example, the XML output is:
 <AuthorityURL>
   <name>an authority</name>
   <href>http://www.organization.org</href>
 </AuthorityURL>
 
 

Author:
Emmanuel Blondel - emmanuel.blondel1@gmail.com | emmanuel.blondel@fao.org

Constructor Summary
GSAuthorityURLInfoEncoder()
          Constructs a new GSAuthorityURLInfoEncoder
GSAuthorityURLInfoEncoder(String name, String href)
          Constructs quickly an AuthorityURL info
 
Method Summary
 boolean delHref()
          Deletes the href
protected  boolean delMember(AuthorityURLInfo type)
          Deletes an AuthorityURLInfo member
 boolean delName()
          Deletes the authority name
static org.jdom.filter.Filter getFilterByHref(String href)
          Get a Filter using the AuthorityURLInfo href (authorityURL)
 String getHref()
          Get the href
protected  String getMember(AuthorityURLInfo type)
          Get the value of the AuthorityURLInfo member
 String getName()
          Get the name
 void setHref(String href)
          Set the href
protected  void setMember(AuthorityURLInfo type, String value)
          Set an AuthorityURLInfo member (name, href)
 void setName(String name)
          Set the name
protected  void setup(String name, String href)
          Set-up quickly an AuthorityURL info
 
Methods inherited from class it.geosolutions.geoserver.rest.encoder.utils.XmlElement
add, add, addContent, getRoot, isEmpty, remove, set, set, setRoot, setRoot, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GSAuthorityURLInfoEncoder

public GSAuthorityURLInfoEncoder()
Constructs a new GSAuthorityURLInfoEncoder


GSAuthorityURLInfoEncoder

public GSAuthorityURLInfoEncoder(String name,
                                 String href)
Constructs quickly an AuthorityURL info

Parameters:
name - (required)
href - (required)
Method Detail

getFilterByHref

public static org.jdom.filter.Filter getFilterByHref(String href)
Get a Filter using the AuthorityURLInfo href (authorityURL)

Parameters:
href -
Returns:
the filter

setup

protected void setup(String name,
                     String href)
Set-up quickly an AuthorityURL info

Parameters:
name -
href -

setMember

protected void setMember(AuthorityURLInfo type,
                         String value)
Set an AuthorityURLInfo member (name, href)

Parameters:
type -
value -

setName

public void setName(String name)
Set the name

Parameters:
name -

setHref

public void setHref(String href)
Set the href

Parameters:
href -

delMember

protected boolean delMember(AuthorityURLInfo type)
Deletes an AuthorityURLInfo member

Parameters:
type -
Returns:
true if the AuthorityURLInfo member is removed

delName

public boolean delName()
Deletes the authority name

Returns:
true if removed

delHref

public boolean delHref()
Deletes the href

Returns:
true if removed

getMember

protected String getMember(AuthorityURLInfo type)
Get the value of the AuthorityURLInfo member

Parameters:
type -
Returns:
the value of the AuthorityURLInfo member

getName

public String getName()
Get the name

Returns:

getHref

public String getHref()
Get the href

Returns:


Copyright © 2007-2014 GeoSolutions. All Rights Reserved.