Package org.apache.abdera.model

Examples of org.apache.abdera.model.Text

Per RFC4287:

 A Text construct contains human-readable text, usually in small quantities.  The content of Text constructs is Language-Sensitive. atomPlainTextConstruct = atomCommonAttributes, attribute type { "text" | "html" }?, text atomXHTMLTextConstruct = atomCommonAttributes, attribute type { "xhtml" }, xhtmlDiv atomTextConstruct = atomPlainTextConstruct | atomXHTMLTextConstruct 

    return (title != null) ? title.getValue() : null;
  }

  private Text setTitle(String title, Text.Type type) {
    FOMFactory fomfactory = (FOMFactory) factory;
    Text text = fomfactory.newText(PREFIXED_TITLE,type);
    text.setValue(title);
    this._setChild(PREFIXED_TITLE, (OMElement) text);
    return text;
  }
View Full Code Here


      for (Person a : authors) {
        e.addAuthor(a);
      }
    }
   
    Text t = getSummary(entryObj, request);
    if (t != null) {
      e.setSummaryElement(t);
    }
    return link;
  }
View Full Code Here

    }
  }

  @Override
  public Text getSummary(Node entry, RequestContext request) throws ResponseContextException {
    Text summary = request.getAbdera().getFactory().newSummary();
    summary.setText(getStringOrNull(entry, SUMMARY));
    return summary;
  }
View Full Code Here

      throws OMException {
    super(WORKSPACE, parent, factory, builder);
  }
 
  public String getTitle() {
    Text title = this.getFirstChild(TITLE);
    return (title != null) ? title.getValue() : null;
  }
View Full Code Here

    return (title != null) ? title.getValue() : null;
  }

  private Text setTitle(String title, Text.Type type) {
    FOMFactory fomfactory = (FOMFactory) factory;
    Text text = fomfactory.newText(PREFIXED_TITLE,type);
    text.setValue(title);
    this._setChild(PREFIXED_TITLE, (OMElement) text);
    return text;
  }
View Full Code Here

    }

    public Text setRights(String value) {
        complete();
        FOMFactory factory = (FOMFactory)this.factory;
        Text text = factory.newRights();
        text.setValue(value);
        setRightsElement(text);
        return text;
    }
View Full Code Here

        return setRights(value, Text.Type.XHTML);
    }

    public Text setRights(String value, Text.Type type) {
        FOMFactory factory = (FOMFactory)this.factory;
        Text text = factory.newRights(type);
        text.setValue(value);
        setRightsElement(text);
        return text;
    }
View Full Code Here

        return text;
    }

    public Text setRights(Div value) {
        FOMFactory factory = (FOMFactory)this.factory;
        Text text = factory.newRights(Text.Type.XHTML);
        text.setValueElement(value);
        setRightsElement(text);
        return text;
    }
View Full Code Here

    }

    public Text setSubtitle(String value) {
        complete();
        FOMFactory factory = (FOMFactory)this.factory;
        Text text = factory.newSubtitle();
        text.setValue(value);
        setSubtitleElement(text);
        return text;
    }
View Full Code Here

        return setSubtitle(value, Text.Type.XHTML);
    }

    public Text setSubtitle(String value, Text.Type type) {
        FOMFactory factory = (FOMFactory)this.factory;
        Text text = factory.newSubtitle(type);
        text.setValue(value);
        setSubtitleElement(text);
        return text;
    }
View Full Code Here

TOP

Related Classes of org.apache.abdera.model.Text

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.