-
Notifications
You must be signed in to change notification settings - Fork 440
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
style: change some names to make the code more readable
- Loading branch information
Showing
5 changed files
with
30 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
import { ParameterObject } from '../interfaces/open-api-spec.interface'; | ||
|
||
export class GlobalParametersStorageHost { | ||
private parameters = new Array<ParameterObject>(); | ||
|
||
add(...parameters: ParameterObject[]) { | ||
this.parameters.push(...parameters); | ||
} | ||
|
||
getAll() { | ||
return this.parameters; | ||
} | ||
|
||
clear() { | ||
this.parameters = []; | ||
} | ||
} | ||
|
||
const globalRef = global as any; | ||
export const GlobalParametersStorage: GlobalParametersStorageHost = | ||
globalRef.SwaggerGlobalParametersStorage || | ||
(globalRef.SwaggerGlobalParametersStorage = | ||
new GlobalParametersStorageHost()); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters