| | |
| | | * CDDL HEADER END |
| | | * |
| | | * |
| | | * Copyright 2006-2008 Sun Microsystems, Inc. |
| | | * Copyright 2006-2009 Sun Microsystems, Inc. |
| | | */ |
| | | package org.opends.server.replication.protocol; |
| | | |
| | |
| | | public byte[] getBytes(short reqProtocolVersion) |
| | | throws UnsupportedEncodingException |
| | | { |
| | | // Of course, always support current protocol version |
| | | if (reqProtocolVersion == ProtocolVersion.getCurrentVersion()) |
| | | { |
| | | return getBytes(); |
| | | } |
| | | else |
| | | { |
| | | throw new UnsupportedEncodingException(getClass().getSimpleName() + |
| | | " PDU does not support requested protocol version serialization: " + |
| | | reqProtocolVersion); |
| | | } |
| | | // There was no change since version 2. |
| | | return getBytes(); |
| | | } |
| | | |
| | | /** |