/**
 * Copyright © 2025 Nevis Security AG. All rights reserved.
 */

/**
 * The configuration related to application attestation.
 *
 * If the backend (nevisFIDO) requires application attestation, you must provide this information,
 * so that the mobile SDK can send the required app integrity information.
 *
 * @group Common Objects
 */
export abstract class AppAttestation {
	/**
	 * The {@link https://cloud.google.com/resource-manager/docs/creating-managing-projects#before_you_begin | Google Cloud project number}.
	 *
	 * > [!IMPORTANT]
	 * > This property is Android specific and will be ignored by iOS native plugin.
	 */
	abstract googleCloudProjectNumber: number;

	/**
	 * Default constructor for {@link AppAttestation}.
	 *
	 * @param googleCloudProjectNumber The Google Cloud project number.
	 * @returns the created {@link AppAttestation} instance.
	 */
	static create(googleCloudProjectNumber: number): AppAttestation {
		return new AppAttestationImpl(googleCloudProjectNumber);
	}
}

export class AppAttestationImpl extends AppAttestation {
	googleCloudProjectNumber: number;

	constructor(googleCloudProjectNumber: number) {
		super();
		this.googleCloudProjectNumber = googleCloudProjectNumber;
	}
}
