mirror of
https://github.com/sasjs/adapter.git
synced 2026-01-10 05:40:06 +00:00
feat(*): recreate package with new name
This commit is contained in:
6
src/types/Context.ts
Normal file
6
src/types/Context.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
export interface Context {
|
||||
name: string;
|
||||
id: string;
|
||||
createdBy: string;
|
||||
version: number;
|
||||
}
|
||||
4
src/types/CsrfToken.ts
Normal file
4
src/types/CsrfToken.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
export interface CsrfToken {
|
||||
headerName: string;
|
||||
value: string;
|
||||
}
|
||||
7
src/types/Folder.ts
Normal file
7
src/types/Folder.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
import { Link } from "./Link";
|
||||
|
||||
export interface Folder {
|
||||
id: string;
|
||||
uri: string;
|
||||
links: Link[];
|
||||
}
|
||||
11
src/types/Job.ts
Normal file
11
src/types/Job.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
import { Link } from "./Link";
|
||||
import { JobResult } from "./JobResult";
|
||||
|
||||
export interface Job {
|
||||
id: string;
|
||||
name: string;
|
||||
uri: string;
|
||||
createdBy: string;
|
||||
links: Link[];
|
||||
results: JobResult;
|
||||
}
|
||||
3
src/types/JobResult.ts
Normal file
3
src/types/JobResult.ts
Normal file
@@ -0,0 +1,3 @@
|
||||
export interface JobResult {
|
||||
"_webout.json": string;
|
||||
}
|
||||
7
src/types/Link.ts
Normal file
7
src/types/Link.ts
Normal file
@@ -0,0 +1,7 @@
|
||||
export interface Link {
|
||||
method: string;
|
||||
rel: string;
|
||||
href: string;
|
||||
uri: string;
|
||||
type: string;
|
||||
}
|
||||
30
src/types/SASjsConfig.ts
Normal file
30
src/types/SASjsConfig.ts
Normal file
@@ -0,0 +1,30 @@
|
||||
import { ServerType } from "./ServerType";
|
||||
|
||||
/**
|
||||
* Specifies the configuration for the SASjs instance.
|
||||
*
|
||||
*/
|
||||
export class SASjsConfig {
|
||||
/**
|
||||
* The location (including http protocol and port) of the SAS Server.
|
||||
* Can be omitted, eg if serving directly from the SAS Web Server or being
|
||||
* streamed.
|
||||
*/
|
||||
serverUrl: string = "";
|
||||
pathSAS9: string = "";
|
||||
pathSASViya: string = "";
|
||||
/**
|
||||
* The appLoc is the parent folder under which the SAS services (STPs or Job
|
||||
* Execution Services) are stored.
|
||||
*/
|
||||
appLoc: string = "";
|
||||
/**
|
||||
* Can be SAS9 or SASVIYA
|
||||
*/
|
||||
serverType: ServerType | null = null;
|
||||
/**
|
||||
* Set to `true` to enable additional debugging.
|
||||
*/
|
||||
debug: boolean = true;
|
||||
contextName: string = "";
|
||||
}
|
||||
12
src/types/SASjsRequest.ts
Normal file
12
src/types/SASjsRequest.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
/**
|
||||
* Represents a SASjs request, its response and logs.
|
||||
*
|
||||
*/
|
||||
export interface SASjsRequest {
|
||||
serviceLink: string;
|
||||
timestamp: Date;
|
||||
sourceCode: string;
|
||||
generatedCode: string;
|
||||
logFile: string;
|
||||
SASWORK: any;
|
||||
}
|
||||
14
src/types/SASjsWaitingRequest.ts
Normal file
14
src/types/SASjsWaitingRequest.ts
Normal file
@@ -0,0 +1,14 @@
|
||||
/**
|
||||
* Represents requests that are queued, pending a signon event
|
||||
*
|
||||
*/
|
||||
export interface SASjsWaitingRequest {
|
||||
requestPromise: {
|
||||
promise: any;
|
||||
resolve: any;
|
||||
reject: any;
|
||||
};
|
||||
SASjob: string;
|
||||
data: any;
|
||||
params?: any;
|
||||
}
|
||||
8
src/types/ServerType.ts
Normal file
8
src/types/ServerType.ts
Normal file
@@ -0,0 +1,8 @@
|
||||
/**
|
||||
* Server type - Viya or SAS9.
|
||||
*
|
||||
*/
|
||||
export enum ServerType {
|
||||
SASViya = "SASVIYA",
|
||||
SAS9 = "SAS9",
|
||||
}
|
||||
3
src/types/Session.ts
Normal file
3
src/types/Session.ts
Normal file
@@ -0,0 +1,3 @@
|
||||
export interface Session {
|
||||
id: string;
|
||||
}
|
||||
10
src/types/index.ts
Normal file
10
src/types/index.ts
Normal file
@@ -0,0 +1,10 @@
|
||||
export * from "./Context";
|
||||
export * from "./CsrfToken";
|
||||
export * from "./Folder";
|
||||
export * from "./Job";
|
||||
export * from "./Link";
|
||||
export * from "./SASjsConfig";
|
||||
export * from "./SASjsRequest";
|
||||
export * from "./SASjsWaitingRequest";
|
||||
export * from "./ServerType";
|
||||
export * from "./Session";
|
||||
Reference in New Issue
Block a user