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;
    }
}

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;
    private String token;


    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;
    }


    /**
     * Token generated by the owner of initiator peer. To be used 
     * in kurjun if the request is approved by the remote peer.
     */
    public String getToken()
    {
        return token;
    }


    /**
     * Token generated by the owner of initiator peer. To be used 
     * in kurjun if the request is approved by the remote peer.
     */
    public void setToken( String token )
    {
        this.token = token;
    }
    
}

Add token to be transfered between registered peers