Package org.opennms.netmgt.rtc.datablock
Class HttpPostInfo
- java.lang.Object
-
- org.opennms.netmgt.rtc.datablock.HttpPostInfo
-
public class HttpPostInfo extends java.lang.Object
Class containing the information for the HTTP POST operations - this gets constructed when each time a subscribe event is received and is basically immutable (except for error count).- Author:
- Sowmya Nataraj
-
-
Constructor Summary
Constructors Constructor Description HttpPostInfo(java.lang.String hurl, java.lang.String clabel, java.lang.String user, java.lang.String passwd)
ConstructorHttpPostInfo(java.net.URL hurl, java.lang.String clabel, java.lang.String user, java.lang.String passwd)
Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clearErrors()
Clear error count if there were errors earlierboolean
equals(java.lang.Object obj)
java.lang.String
getCategory()
Return the category labelint
getErrors()
Return the number of errorsjava.lang.String
getPassword()
Return the passwdjava.net.URL
getURL()
Return the URLjava.lang.String
getURLString()
Return the URL as a stringjava.lang.String
getUser()
Return the userint
hashCode()
void
incrementErrors()
Increment errors
-
-
-
Constructor Detail
-
HttpPostInfo
public HttpPostInfo(java.net.URL hurl, java.lang.String clabel, java.lang.String user, java.lang.String passwd)
Constructor- Parameters:
hurl
- aURL
object.clabel
- aString
object.user
- aString
object.passwd
- aString
object.
-
HttpPostInfo
public HttpPostInfo(java.lang.String hurl, java.lang.String clabel, java.lang.String user, java.lang.String passwd) throws java.net.MalformedURLException
Constructor- Parameters:
hurl
- aString
object.clabel
- aString
object.user
- aString
object.passwd
- aString
object.- Throws:
java.net.MalformedURLException
- thrown if the string url passed is not a valid urljava.net.MalformedURLException
- if any.
-
-
Method Detail
-
incrementErrors
public void incrementErrors()
Increment errors
-
clearErrors
public void clearErrors()
Clear error count if there were errors earlier
-
getURL
public java.net.URL getURL()
Return the URL- Returns:
- the URL
-
getURLString
public java.lang.String getURLString()
Return the URL as a string- Returns:
- the URL as a string
-
getCategory
public java.lang.String getCategory()
Return the category label- Returns:
- the category label
-
getUser
public java.lang.String getUser()
Return the user- Returns:
- the user
-
getPassword
public java.lang.String getPassword()
Return the passwd- Returns:
- the passwd
-
getErrors
public int getErrors()
Return the number of errors- Returns:
- the number of errors
-
hashCode
public int hashCode()
- Overrides:
hashCode
in classjava.lang.Object
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equals
in classjava.lang.Object
-
-