UNPKG

@specs-feup/kadabra

Version:

A Java source-to-source compiler written in Typescript

67 lines 2.76 kB
import { App, Call, Class, FileJp, InterfaceType, Method } from "../../Joinpoints.js"; /** * Prepares a given method call by: <br> * * extracting a functional interface <br> * * create a field of that type <br> * * initialize the field with the called method <br> * * replace the call with invocation of the field method <br> * NOTE: This is an alias for "PrepareCall" aspect */ export declare function ExtractToField($call: Call | undefined | null, $method: Method | undefined | null, $fieldLocation: Class | undefined | null, newFile?: boolean, $funcInterface?: InterfaceType | undefined | null): { $field: null; $interface: InterfaceType | null; $interfaceMethod: undefined; defaultMethod: undefined; } | { $field: import("../../Joinpoints.js").Field | undefined; $interface: InterfaceType; $interfaceMethod: Method | undefined; defaultMethod: string; } | { $field: undefined; $interface: undefined; $interfaceMethod: undefined; defaultMethod: undefined; }; /** * Prepares a given method call by: <br> * * extracting a functional interface <br> * * create a field of that type <br> * * initialize the field with the called method <br> * * replace the call with invocation of the field method */ export declare function PrepareCall($method?: Method | null, $call?: Call | null, $fieldLocation?: Class | undefined | null, newFile?: boolean, $funcInterface?: InterfaceType | undefined | null): { $field: null; $interface: InterfaceType | null; $interfaceMethod: undefined; defaultMethod: undefined; } | { $field: import("../../Joinpoints.js").Field | undefined; $interface: InterfaceType; $interfaceMethod: Method | undefined; defaultMethod: string; }; export declare function ExtractFunctionalInterface(targetMethod: string, targetClass?: string, targetFile?: string, associate?: boolean, newFile?: boolean): { $interface: InterfaceType; $defaultMethod: Method | undefined; $function: Method; targetMethodName: string; }; export declare function NewMappingClass($interface: InterfaceType, methodName: string, getterType: string, $target?: Class | App | FileJp): { $mapClass: Class; put: (key: string, value: string) => string; contains: (key: string) => string; get: (param: string, defaultMethod?: string) => string; }; export declare function NewFunctionalMethodCaller2($interface?: InterfaceType | null, methodName?: string | null, getterType?: string | null, defaultMethodStr?: string | null): { $mapClass: undefined; put: string; contains: string; get: undefined; } | { $mapClass: Class; put: string; contains: string; get: (param: string) => string; }; //# sourceMappingURL=Specializer.d.ts.map