public void encode(OutputStream out) throws IOException {
  if (version == V1) {
    return;
  }
  DerOutputStream tmp=new DerOutputStream();
  tmp.putInteger(version);
  DerOutputStream seq=new DerOutputStream();
  seq.write(DerValue.createTag(DerValue.TAG_CONTEXT,true,(byte)0),tmp);
  out.write(seq.toByteArray());
}

public void encode ( OutputStream out ) throws IOException { if ( version == V1 ) { return ; } DerOutputStream tmp = new DerOutputStream ( ) ; tmp . putInteger ( version ) ; DerOutputStream seq = new DerOutputStream ( ) ; seq . write ( DerValue . createTag ( DerValue . TAG_CONTEXT , true , ( byte ) 0 ) , tmp ) ; out . write ( seq . toByteArray ( ) ) ; }
encode the certificateversion period in der form to the stream .
