MCPcopy Create free account
hub / github.com/ReadyTalk/avian / readLine

Method readLine

classpath/java/io/ObjectInputStream.java:116–131  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

114 }
115
116 public String readLine() throws IOException {
117 int c = read();
118 if (c < 0) {
119 return null;
120 } else if (c == '\n') {
121 return "";
122 }
123 StringBuilder builder = new StringBuilder();
124 for (;;) {
125 builder.append((char)c);
126 c = read();
127 if (c < 0 || c == '\n') {
128 return builder.toString();
129 }
130 }
131 }
132
133 public void close() throws IOException {
134 in.close();

Callers

nothing calls this directly

Calls 3

readMethod · 0.95
appendMethod · 0.95
toStringMethod · 0.95

Tested by

no test coverage detected