package io.subutai.common.peer;


import org.codehaus.jackson.annotate.JsonIgnore;


/**
 * Registration DTO
 */
public class RegistrationData
{
    private PeerInfo peerInfo;
    @JsonIgnore
    private String keyPhrase;
    private RegistrationStatus status;
    private Encrypted data;


    public RegistrationData()
    {
    }


    public RegistrationData( final PeerInfo peerInfo, final String keyPhrase, final RegistrationStatus status )
    {
        this.peerInfo = peerInfo;
        this.keyPhrase = keyPhrase;
        this.status = status;
    }


    public RegistrationData( final PeerInfo peerInfo, final RegistrationStatus status )
    {
        this.peerInfo = peerInfo;
        this.status = status;
    }


    public PeerInfo getPeerInfo()
    {
        return peerInfo;
    }


    public void setPeerInfo( final PeerInfo peerInfo )
    {
        this.peerInfo = peerInfo;
    }


    public String getKeyPhrase()
    {
        return keyPhrase;
    }


    public RegistrationStatus getStatus()
    {
        return status;
    }


    public void setStatus( final RegistrationStatus status )
    {
        this.status = status;
    }


    public Encrypted getData()
    {
        return data;
    }


    public void setData( final Encrypted data )
    {
        this.data = data;
    }


    public void setKeyPhrase( final String keyPhrase )
    {
        this.keyPhrase = keyPhrase;
    }
}

@@ -282,16 +282,42 @@
 d data;%0A
+    private String token;%0A
 %0A%0A    pu
@@ -1436,10 +1436,457 @@
 ;%0A    %7D%0A
+%0A%0A    /**%0A     * Token generated by the owner of initiator peer. To be used %0A     * in kurjun if the request is approved by the remote peer.%0A     */%0A    public String getToken()%0A    %7B%0A        return token;%0A    %7D%0A%0A%0A    /**%0A     * Token generated by the owner of initiator peer. To be used %0A     * in kurjun if the request is approved by the remote peer.%0A     */%0A    public void setToken( String token )%0A    %7B%0A        this.token = token;%0A    %7D%0A    %0A
 %7D%0A

Add token to be transfered between registered peers