export class URLReviver {
    nativeTypeName() {
        return "URL";
    }
    isInstance(value) {
        return value instanceof URL;
    }
    serialize(value) {
        return { __nativeType: this.nativeTypeName(), href: value.href };
    }
    validate(value) {
        return typeof value.href === "string";
    }
    revive(value) {
        return new URL(value.href);
    }
}
