@autorest/powershell
Version:
AutoRest PowerShell Cmdlet Generator
39 lines • 3.13 kB
TypeScript
import { KnownMediaType } from '@azure-tools/codemodel-v3';
import { Expression, ExpressionOrLiteral, Interface, OneOrMoreStatements, Variable, Property, TypeDeclaration } from '@azure-tools/codegen-csharp';
import { Schema as NewSchema } from '@autorest/codemodel';
import { State } from '../generator';
import { EnhancedTypeDeclaration } from '../schema/extended-type-declaration';
import { ModelClass } from './model-class';
import { TypeContainer } from '@azure-tools/codegen-csharp';
import { DeepPartial } from '@azure-tools/codegen';
import { Mutability } from '../../utils/schema';
export declare function addInfoAttribute(targetProperty: Property, pType: TypeDeclaration, isRequired: boolean, isReadOnly: boolean, description: string, serializedName: string): void;
export declare function newAddInfoAttribute(targetProperty: Property, pType: TypeDeclaration, isRequired: boolean, isReadOnly: boolean, mutability: Mutability, description: string, serializedName: string): void;
export declare class ModelInterface extends Interface implements EnhancedTypeDeclaration {
classImplementation: ModelClass;
state: State;
get schema(): NewSchema;
get defaultOfType(): Expression;
get convertObjectMethod(): string;
deserializeFromContainerMember(mediaType: KnownMediaType, container: ExpressionOrLiteral, serializedName: string, defaultValue: Expression): Expression;
deserializeFromNode(mediaType: KnownMediaType, node: ExpressionOrLiteral, defaultValue: Expression): Expression;
/** emits an expression to deserialize content from a string */
deserializeFromString(mediaType: KnownMediaType, content: ExpressionOrLiteral, defaultValue: Expression): Expression | undefined;
/** emits an expression to deserialize content from a content/response */
deserializeFromResponse(mediaType: KnownMediaType, content: ExpressionOrLiteral, defaultValue: Expression): Expression | undefined;
/** emits an expression serialize this to a HttpContent */
serializeToContent(mediaType: KnownMediaType, value: ExpressionOrLiteral, mode: Expression): Expression;
serializeToNode(mediaType: KnownMediaType, value: ExpressionOrLiteral, serializedName: string, mode: Expression): Expression;
serializeToContainerMember(mediaType: KnownMediaType, value: ExpressionOrLiteral, container: Variable, serializedName: string, mode: Expression): OneOrMoreStatements;
get isXmlAttribute(): boolean;
isNullable: boolean;
get isRequired(): boolean;
validatePresence(eventListener: Variable, property: Variable): OneOrMoreStatements;
validateValue(eventListener: Variable, property: Variable): OneOrMoreStatements;
get hasHeaderProperties(): boolean;
constructor(parent: TypeContainer, interfaceName: string, classImplementation: ModelClass, state: State, objectInitializer?: DeepPartial<ModelInterface>);
get isInternal(): boolean;
init(): this;
addInfoAttribute(p: Property, pType: TypeDeclaration, isRequired: boolean, internalSet: boolean, mutability: Mutability, description: string, serializedName: string): void;
}
//# sourceMappingURL=interface.d.ts.map