📄 pubsubentitybuilder.java
字号:
package edu.ou.kmi.buddyspace.plugins.pubsub.xml;
/*
* PubsubEntityBuilder.java
*
* Project: BuddySpace
* (C) Copyright Knowledge Media Institute 2003
*
*
* Created on 9 October 2003, 18:47
*/
import java.util.*;
import org.jabber.jabberbeans.util.*;
import org.jabber.jabberbeans.*;
import org.jabber.jabberbeans.Extension.*;
/**
* <code>PubsubEntityBuilder</code> is used to construct PubsubEntity objects
*
* @author Jiri Komzak, Knowledge Media Institute, Open University, United Kingdom
*/
public class PubsubEntityBuilder
{
/** Node name */
private String node;
/** JID */
private JID jid;
/** Subscription */
private String subscription;
/** Affilitation */
private String affiliation;
/** Subscribe-options */
private PubsubSubscribeOpt subOpt;
/** Error code */
private String errCode;
/** Error text */
private String errText;
/*
* Construct a new <code>PubsubEntityBuilder</code> object
*/
public PubsubEntityBuilder()
{reset();}
/** reset this builder to a default state, for reuse */
public void reset() {
jid = null;
node = null;
subOpt = null;
subscription = null;
affiliation = null;
}
/* returns subscribe-options */
public PubsubSubscribeOpt getSubscribeOpt() {
return subOpt;
}
/* sets subscribe-options */
public void setSubscribeOpt(PubsubSubscribeOpt newSubOpt) {
this.subOpt = newSubOpt;
}
/* returns the node name */
public String getNode() {
return node;
}
/* sets node name */
public void setNode(String newNode) {
this.node = newNode;
}
/* returns the subscription */
public String getSubscription() {
return subscription;
}
/* sets subscription */
public void setSubscription(String newSubscription) {
this.subscription = newSubscription;
}
/* returns the affiliation */
public String getAffiliation() {
return affiliation;
}
/* sets affiliation */
public void setAffiliation(String newAffiliation) {
this.affiliation = newAffiliation;
}
/* returns the JID */
public JID getJID() {
return jid;
}
/* sets JID */
public void setJID(JID newJID) {
this.jid = newJID;
}
/* returns the error code */
public String getErrorCode() {
return errCode;
}
/* sets error code */
public void setErrorCode(String newErrorCode) {
this.errCode = newErrorCode;
}
/* returns the error text */
public String getErrorText() {
return errText;
}
/* sets error text */
public void setErrorText(String newErrorText) {
this.errText = newErrorText;
}
/*
* Build a <code>PubsubEntity</code> based on the current builder
* state.
*
* @return <code>PubsubEntity</code> based on the current builder
* state.
*/
public XMLData build() throws InstantiationException
{return new PubsubEntity(this);}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -