|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.restlet.util.Couple<String,String>
org.restlet.data.Parameter
public class Parameter
Multi-usage parameter. Note that the name and value properties are thread safe, stored in volatile members.
| Constructor Summary | |
|---|---|
Parameter()
Default constructor. |
|
Parameter(String name,
String value)
Preferred constructor. |
|
| Method Summary | |
|---|---|
int |
compareTo(Parameter o)
|
static Parameter |
create(CharSequence name,
CharSequence value)
Creates a parameter. |
void |
encode(Appendable buffer,
CharacterSet characterSet)
Encodes the parameter into the target buffer. |
String |
encode(CharacterSet characterSet)
Encodes the parameter as a string. |
boolean |
equals(Object obj)
|
String |
getName()
Returns the name of this parameter. |
String |
getValue()
Returns the value. |
int |
hashCode()
|
void |
setName(String name)
|
void |
setValue(String value)
Sets the value. |
String |
toString()
|
| Methods inherited from class org.restlet.util.Couple |
|---|
getFirst, getSecond, setFirst, setSecond |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Parameter()
public Parameter(String name,
String value)
name - The name.value - The value.| Method Detail |
|---|
public static Parameter create(CharSequence name,
CharSequence value)
name - The parameter name buffer.value - The parameter value buffer (can be null).
IOExceptionpublic int compareTo(Parameter o)
compareTo in interface Comparable<Parameter>
public void encode(Appendable buffer,
CharacterSet characterSet)
throws IOException
buffer - The target buffer.characterSet - The character set to use.
IOException
public String encode(CharacterSet characterSet)
throws IOException
characterSet - The character set to use.
IOExceptionpublic boolean equals(Object obj)
equals in class Couple<String,String>public String getName()
NamedValue
getName in interface NamedValue<String>public String getValue()
NamedValue
getValue in interface NamedValue<String>public int hashCode()
hashCode in class Couple<String,String>public void setName(String name)
public void setValue(String value)
NamedValue
setValue in interface NamedValue<String>value - The value.public String toString()
toString in class Couple<String,String>
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||