MCPcopy Create free account
hub / github.com/boxbeam/RedLib / toString

Method toString

src/redempt/redlib/region/MultiRegion.java:725–734  ·  view source on GitHub ↗

Converts this MultiRegion to a String which can be converted back to a MultiRegion using MultiRegion#fromString(String) Please use this to persist MultiRegions, as most of the operations for manipulating a MultiRegion are far more expensive than the same operations would be for a Region. If

()

Source from the content-addressed store, hash-verified

723 * @return The String representation of this MultiRegion
724 */
725 @Override
726 public String toString() {
727 StringBuilder builder = new StringBuilder(getWorld().getName()).append(" ");
728 for (Region region : regions) {
729 String str = region.toString();
730 str = str.substring(str.indexOf(' ') + 1);
731 builder.append(str).append(",");
732 }
733 return builder.substring(0, builder.length() - 1);
734 }
735
736 /**
737 * Turns a String generated by {@link MultiRegion#toString()} back into a MultiRegion

Callers

nothing calls this directly

Calls 6

appendMethod · 0.80
indexOfMethod · 0.80
toStringMethod · 0.65
getNameMethod · 0.45
getWorldMethod · 0.45
lengthMethod · 0.45

Tested by

no test coverage detected