| | |
| | | public ASN1Reader(Socket socket) |
| | | throws IOException |
| | | { |
| | | |
| | | this.socket = socket; |
| | | inputStream = socket.getInputStream(); |
| | | |
| | |
| | | */ |
| | | public ASN1Reader(InputStream inputStream) |
| | | { |
| | | |
| | | this.inputStream = inputStream; |
| | | socket = null; |
| | | maxElementSize = -1; |
| | |
| | | */ |
| | | public int getMaxElementSize() |
| | | { |
| | | |
| | | return maxElementSize; |
| | | } |
| | | |
| | |
| | | */ |
| | | public void setMaxElementSize(int maxElementSize) |
| | | { |
| | | |
| | | this.maxElementSize = maxElementSize; |
| | | } |
| | | |
| | |
| | | public int getIOTimeout() |
| | | throws IOException |
| | | { |
| | | |
| | | if (socket == null) |
| | | { |
| | | return -1; |
| | |
| | | public void setIOTimeout(int ioTimeout) |
| | | throws IOException |
| | | { |
| | | |
| | | if (socket == null) |
| | | { |
| | | return; |
| | |
| | | */ |
| | | public void close() |
| | | { |
| | | |
| | | try |
| | | { |
| | | inputStream.close(); |