/**
 * Copyright © 2023-2024 Nevis Security AG. All rights reserved.
 */

import { ChannelMessage } from '../ChannelMessage';

/**
 * Holds the parameters of the PIN enrollment call.
 */
export class PinEnrollMessage extends ChannelMessage {
	/**
	 * The identifier of the operation.
	 */
	operationId: string;

	/**
	 * The PIN.
	 */
	pin: string[];

	/**
	 * Default constructor for {@link PinEnrollMessage}.
	 *
	 * @param operationId the identifier of the operation.
	 * @param pin the PIN.
	 */
	constructor(operationId: string, pin: string) {
		super();

		this.operationId = operationId;
		this.pin = Array.from(pin);
	}
}
