package com.jscape.inet.scp.protocol.messages;

import static com.jscape.util.Parameters.assertNotNull;

/**
 * Directory message.
 *
 * @author Alex Usun
 */
public class DirectoryMessage
        extends Message {

    public final String directoryName;
    public final String directoryMode;

    /**
     * Creates a new message instance.
     *
     * @param directoryName directory name
     * @param directoryMode directory mode
     */
    public DirectoryMessage(String directoryName, String directoryMode) {
        assertNotNull(directoryName);
        this.directoryName = directoryName;

        assertNotNull(directoryMode);
        this.directoryMode = directoryMode;
    }

    @Override
    public String toString() {
        return "DirectoryMessage {"
               + "directoryName='" + this.directoryName + '\''
               + ", directoryMode='" + this.directoryMode + '\''
               + '}';
    }
}
