MCPcopy Create free account
hub / github.com/PCGen/pcgen / appendRaceLine

Method appendRaceLine

code/src/java/pcgen/io/PCGVer2Creator.java:1763–1785  ·  view source on GitHub ↗

@param buffer

(StringBuilder buffer)

Source from the content-addressed store, hash-verified

1761 * @param buffer
1762 */
1763 private void appendRaceLine(StringBuilder buffer)
1764 {
1765 buffer.append(IOConstants.TAG_RACE).append(':');
1766 buffer.append(EntityEncoder.encode(charDisplay.getRace().getKeyName()));
1767 List<String> assocList = thePC.getAssociationList(charDisplay.getRace());
1768 if (assocList != null && !assocList.isEmpty())
1769 {
1770 buffer.append(IOConstants.TAG_SEPARATOR);
1771 buffer.append(IOConstants.TAG_APPLIEDTO).append(IOConstants.TAG_END);
1772 boolean first = true;
1773 for (String assoc : assocList)
1774 {
1775 if (!first)
1776 {
1777 buffer.append(Constants.COMMA);
1778 }
1779 first = false;
1780 buffer.append(EntityEncoder.encode(assoc));
1781 }
1782 }
1783 appendAddTokenInfo(buffer, charDisplay.getRace());
1784 buffer.append(IOConstants.LINE_SEP);
1785 }
1786
1787 private void appendFavoredClassLine(StringBuilder buffer)
1788 {

Callers 1

createPCGStringMethod · 0.95

Calls 7

encodeMethod · 0.95
appendAddTokenInfoMethod · 0.95
getKeyNameMethod · 0.65
isEmptyMethod · 0.65
appendMethod · 0.45
getRaceMethod · 0.45
getAssociationListMethod · 0.45

Tested by

no test coverage detected