This will return the single-line textual representation. This was crafted
for the command line client. Your mileage may vary.

@return the single line description
481285
public String asString() {
    StringBuffer buf = new StringBuffer();
    buf.append(" PID: [ ").append(this.id).append(" ]");;
    buf.append(" CID: [ ").append(this.clientId).append(" ]");;
    buf.append(" DES: [ ").append(this.desVersion).append(" ]");;
    buf.append(" SCIDS: [ " );
    for (String scid : serviceContractIDs) {
      buf.append(scid).append(" ");
    }
    buf.append("]");
    buf.append(" SIIDS: [ " );
    for (String siid : serviceInstanceIDs) {
      buf.append(siid).append(" ");
    }
    buf.append("]");
    buf.append(" RESPOND_TO: [ " );
    for (RespondToURL rt : respondToURLs) {
      buf.append(rt.label).append(", ").append(rt.url).append(" ");
    }
    buf.append("]");
    buf.append(" PAYLOAD_TYPE: [ ").append(respondToPayloadType).append(" ]");
    
    return buf.toString();
  }
726942
public String getNextLine() {
		if (!isNextLine()) {
			return null;
		}
		if (isTag(nextLine))
			return FlatFileUtils.trimRight(nextLine,
					getTagWidth(nextLine));
		else
			return nextLine.trim();
	}
81257
public String getText()
   {
      
     //convert textable to map of text
	   Object key = null;
      try 
      {
    	  //read bindTemplate
          String bindTemplate = getTemplate();
         Map<Object,String> textMap = new Hashtable<Object,String>();
    
         for(Map.Entry<String, Textable> entry: map.entrySet())
         {
            key = entry.getKey();
            try
			{
				//convert to text
				textMap.put(key,(entry.getValue()).getText());
			}
			catch (Exception e)
			{
				throw new SystemException("Unable to build text for key:"+key+" error:"+e.getMessage(),e);
			}         
         }
         
         Debugger.println(this, "bindTemplate="+bindTemplate);
         String formattedOutput = Text.format(bindTemplate, textMap);
         Debugger.println(this, "formattedOutput="+formattedOutput);
         return formattedOutput;
         
      } 
      catch (RuntimeException e) 
      {
         throw e;
      }
      catch (Exception e) 
      {
         throw new SetupException(e.getMessage(),e);
      }
   }
944831
public String getContent() {
		String content = "";
		
		NodeList list = dom.getChildNodes();
		for (int i=0;i<list.getLength();i++) {
			if (list.item(i) instanceof Text) {
				content += (list.item(i).getNodeValue());
			}
		}
		
		return content;
	}
894800
public String getMessage() {
        if ( this.cause == null ) {
            return super.getMessage() + " Line number: " + this.lineNumber;
        } else {
            return super.getMessage() + " Line number: " + this.lineNumber + ". Caused by: " + this.cause.getMessage();
        }
    }
868437
private String readTrimmedLine() throws IOException {
        String line = readLine();
        if (line != null)
            return line.trim();
        else
            throw new EOFException();
    }
753156
public String wholeText() {
        final StringBuilder accum = StringUtil.borrowBuilder();
        NodeTraversor.traverse(new NodeVisitor() {
            public void head(Node node, int depth) {
                if (node instanceof TextNode) {
                    TextNode textNode = (TextNode) node;
                    accum.append(textNode.getWholeText());
                }
            }

            public void tail(Node node, int depth) {
            }
        }, this);

        return StringUtil.releaseBuilder(accum);
    }
359019
public String description() {
	Util.out4.println("DeviceImpl.description() arrived");

	//
	// Record attribute request in black box
	//

	blackbox.insert_attr(Attr_Description);

	//
	// Return data to caller
	//

	Util.out4.println("Leaving DeviceImpl.description()");
	return desc;
    }
152580
@Exported
    public String getDescription() {
        Set<Node> nodes = getNodes();
        if(nodes.isEmpty()) {
            Set<Cloud> clouds = getClouds();
            if(clouds.isEmpty())
                return Messages.Label_InvalidLabel();

            return Messages.Label_ProvisionedFrom(toString(clouds));
        }

        if(nodes.size()==1)
            return nodes.iterator().next().getNodeDescription();

        return Messages.Label_GroupOf(toString(nodes));
    }
95205
public String getHelpText() {
		@SuppressWarnings("unchecked")
		ArrayList<Argument> arguments = (ArrayList<Argument>) this.args.clone();
		String ret = programDescription + "\n";
		ret += "Usage: " + executableName + " ";
		for (Argument arg : this.args) {
			if (arg.isParam) {
				ret += !arg.isRequiredArg() 
						? "["
						: "";
				ret += arg.longOption;
				
				ret += !arg.isRequiredArg() 
						? "]"
						: "";
				ret += arg.isMultipleAllowed()
						? "..."
						: "";
				ret += " ";
				
				arguments.remove(arg);
			}
		}
		for (Argument arg : arguments) {
			if (arg.isRequiredArg()) {
				ret += !arg.isRequiredArg() 
						? "["
						: "";
				ret += arg.getLongOption() == null ? "-" + arg.getOption()
						: "--" + arg.getLongOption();
				
				ret += !arg.isRequiredArg() 
						? "]"
						: "";
				ret += arg.isMultipleAllowed()
						? "..."
						: "";
				ret += " ";
			}
		}
		ret += "[OPTION]";
		ret += arguments.size() > 1
				? "... "
				: " ";
		ret += "\n" + usageHint + "\n";
		ArrayList<String> col1 = new ArrayList<String>();
		ArrayList<String> col2 = new ArrayList<String>();
		for (Argument option : arguments) {
			String line = option.getOption() != null ? String.format("  %-5s",
					"-" + option.option
							+ (option.getLongOption() != null ? "," : ""))
					: String.format("  %-5s", "");
			line += option.getLongOption() != null ? "--"
					+ option.longOption
					+ (option.getValueHint().length() > 0
							&& option.takesValue() ? "="
							+ option.getValueHint() : "") : "";
			col1.add(line);
			col2.add(option.helpText);
		}
		ret += theColumnator((String[]) col1.toArray(new String[] {}),
				(String[]) col2.toArray(new String[] {}), 2, 80);
		return ret;
	}
107517
public List<String> getHelp() {

		List<String> out = new ArrayList<>();

		if (helpAppVersion != null) {
			out.add(helpAppVersion);
		}

		if (helpAppExample != null) {
			out.add(helpAppExample);
		}

		if (helpAppVersion != null || helpAppExample != null) {
	 		out.add(""); // new line
 		}

		// find longest option to format all other options by this one
		int max = 0;
		for (CommandOption option: options) {
			String command = option.toCommandString();
			max = Math.max(max, command.length());
		}

		for (CommandOption option: options) {
			String info = option.toCommandString();
			int spaces = max - info.length() + 1;

			String delimiter = new String(new char[spaces]).replace("\0", " "); // returns 'spaces' long empty string

			info = info + delimiter + option.getDescription();
			out.add(info);
		}

		return out;

	}
1027011
public Text nextLine() {
        if (linePointer == 0) {
            linePointer = pos;
        } else {
            linePointer++;
        }

        int mark = linePointer;
        int limit = pos + len;

        while (linePointer < limit && chars[linePointer] != '\n') {
            linePointer++;
        }
        
        return new Text(chars, mark, linePointer - mark);
    }
390547
public String getContent() {
        if (content != null) {
            return content;
        }

        if (stream != null) {
            Scanner scanner = new Scanner(stream, "UTF-8").useDelimiter("\\A");

            if (!scanner.hasNext()) {
                return "";
            }

            String data = scanner.next();
            scanner.close();

            return data;
        }

        return "";
    }
282709
public String getHelp() {
		StringBuilder sb = new StringBuilder(data.size() * HELP_TEXT_LENGTH_PER_PARAM);

		sb.append("Required Parameters:");
		sb.append(HELP_TEXT_LINE_DELIMITER);

		for (Option o : data.values()) {
			sb.append(this.helpText(o));
		}
		sb.append(HELP_TEXT_LINE_DELIMITER);

		return sb.toString();
	}
720395
public String getOnlineHelpUriCustom() {

        if (m_onlineHelpUriCustom == null) {
            return null;
        }
        StringBuffer result = new StringBuffer(m_onlineHelpUriCustom.length() + 4);
        result.append("\"");
        result.append(m_onlineHelpUriCustom);
        result.append("\"");
        return result.toString();
    }
1021771
public String tokenizeToText() {

    final StringBuilder sb = new StringBuilder();
    if (isNoSeg) {
      String[] sentences = text.toArray(new String[text.size()]);
      final List<List<Token>> tokens = tokenizer.tokenize(sentences);
      for (final List<Token> tokSentence : tokens) {
        for (final Token tok : tokSentence) {
          String tokenValue = tok.getTokenValue();
          sb.append(tokenValue.trim()).append(DELIMITER);
        }
        sb.append(LINE_BREAK);
      }
    } else {
      final String[] sentences = segmenter.segmentSentence();
      final List<List<Token>> tokens = tokenizer.tokenize(sentences);
      for (final List<Token> tokSentence : tokens) {
        for (final Token token : tokSentence) {
          String tokenValue = token.getTokenValue();
          if (tokenValue.equals(RuleBasedSegmenter.PARAGRAPH)) {
            sb.append(DEFAULT_TOKEN_VALUE).append(LINE_BREAK);
          } else {
            sb.append(tokenValue.trim()).append(DELIMITER);
          }
        }
        sb.append(LINE_BREAK);
      }
    }
    return sb.toString().trim();
  }
338606
@Override
    public String getDescription()
    {
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.entry(tc, "getDescription");

        String desc = _definition.getDescription();

        // Assume that a null description means inherit.
        if (null == desc)
        {
            desc = getTarget().getDescription();
        }

        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled())
            SibTr.exit(tc, "getDescription", desc);

        return desc;
    }