All Downloads are FREE. Search and download functionalities are using the official Maven repository.

Alachisoft.NCache.Common.Activate.ActivateAuthenticationArgs Maven / Gradle / Ivy

There is a newer version: 5.3.3
Show newest version
/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Alachisoft.NCache.Common.Activate;

import Alachisoft.NCache.Common.Common;
import com.alachisoft.ncache.serialization.core.io.InternalCompactSerializable;
import com.alachisoft.ncache.serialization.standard.io.CompactReader;
import com.alachisoft.ncache.serialization.standard.io.CompactWriter;

import java.io.IOException;

/**
 * @author Muneeb_Shahid
 */
public class ActivateAuthenticationArgs implements InternalCompactSerializable {

    private String machineName;
    private String macAddress;
    private String ipAddress;

    public ActivateAuthenticationArgs() {
    }

    public ActivateAuthenticationArgs(String machineName, String macAddress, String ipAddress) {
        this.machineName = machineName;
        this.macAddress = macAddress;
        this.ipAddress = ipAddress;
    }

    public String getMachineName() {
        return machineName;
    }

    public String getMacAddress() {
        return macAddress;
    }

    public String getIpAddress() {
        return ipAddress;
    }

    @Override
    public void Deserialize(CompactReader reader) throws IOException, ClassNotFoundException {
        machineName = Common.as(reader.ReadObject(), String.class);
        macAddress = Common.as(reader.ReadObject(), String.class);
        ipAddress = Common.as(reader.ReadObject(), String.class);
    }

    @Override
    public void Serialize(CompactWriter writer) throws IOException {
        writer.WriteObject(machineName);
        writer.WriteObject(macAddress);
        writer.WriteObject(ipAddress);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy