import { __decorateMetadata } from "../../../../../../_virtual/_@oxc-project_runtime@0.94.0/helpers/decorateMetadata.mjs";
import { __decorate } from "../../../../../../_virtual/_@oxc-project_runtime@0.94.0/helpers/decorate.mjs";
import { IsValidMessageType, parseMessageType } from "../../../util/messageType.mjs";
import { DidCommMessage } from "../../../DidCommMessage.mjs";
import { IsOptional, IsString } from "class-validator";

//#region ../didcomm/src/modules/connections/messages/DidCommTrustPingResponseMessage.ts
/**
* Message to respond to a trust ping message
*
* @see https://github.com/hyperledger/aries-rfcs/blob/master/features/0048-trust-ping/README.md#messages
*/
var DidCommTrustPingResponseMessage = class DidCommTrustPingResponseMessage extends DidCommMessage {
	/**
	* Create new DidCommTrustPingResponseMessage instance.
	* responseRequested will be true if not passed
	* @param options
	*/
	constructor(options) {
		super();
		this.allowDidSovPrefix = true;
		this.type = DidCommTrustPingResponseMessage.type.messageTypeUri;
		if (options) {
			this.id = options.id || this.generateId();
			this.comment = options.comment;
			this.setThread({ threadId: options.threadId });
			if (options.timing) this.setTiming({
				inTime: options.timing.inTime,
				outTime: options.timing.outTime
			});
		}
	}
};
DidCommTrustPingResponseMessage.type = parseMessageType("https://didcomm.org/trust_ping/1.0/ping_response");
__decorate([IsValidMessageType(DidCommTrustPingResponseMessage.type), __decorateMetadata("design:type", Object)], DidCommTrustPingResponseMessage.prototype, "type", void 0);
__decorate([
	IsString(),
	IsOptional(),
	__decorateMetadata("design:type", String)
], DidCommTrustPingResponseMessage.prototype, "comment", void 0);

//#endregion
export { DidCommTrustPingResponseMessage };
//# sourceMappingURL=DidCommTrustPingResponseMessage.mjs.map