(String str, int len)
| 158 | } |
| 159 | |
| 160 | synchronized public void writeClientCutText(String str, int len) |
| 161 | { |
| 162 | startMsg(MsgTypes.msgTypeClientCutText); |
| 163 | os.pad(3); |
| 164 | os.writeU32(len); |
| 165 | Charset latin1 = Charset.forName("ISO-8859-1"); |
| 166 | ByteBuffer bytes = latin1.encode(str); |
| 167 | os.writeBytes(bytes.array(), 0, len); |
| 168 | endMsg(); |
| 169 | } |
| 170 | |
| 171 | synchronized protected void startMsg(int type) { |
| 172 | os.writeU8(type); |