code: public static void writeCircularString(ByteWriter writer,
  			CircularString circularString) throws IOException {
  
  		writer.writeInt(circularString.numPoints());
  
  		for (Point point : circularString.getPoints()) {
  			writePoint(writer, point);
  		}
  	}
docs: Write a Circular String
  
  @param writer
  @param circularString
  @throws IOException