@mcp-abap-adt/adt-clients 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +22 -0
- package/README.md +184 -0
- package/bin/README.md +368 -0
- package/bin/lock-object.js +274 -0
- package/bin/manage-locks.js +331 -0
- package/bin/manage-sessions.js +235 -0
- package/bin/unlock-object.js +291 -0
- package/bin/unlock-test-objects.js +248 -0
- package/dist/clients/CrudClient.d.ts +48 -0
- package/dist/clients/CrudClient.d.ts.map +1 -0
- package/dist/clients/CrudClient.js +135 -0
- package/dist/clients/LockClient.d.ts +28 -0
- package/dist/clients/LockClient.d.ts.map +1 -0
- package/dist/clients/LockClient.js +141 -0
- package/dist/clients/ManagementClient.d.ts +34 -0
- package/dist/clients/ManagementClient.d.ts.map +1 -0
- package/dist/clients/ManagementClient.js +80 -0
- package/dist/clients/ReadOnlyClient.d.ts +70 -0
- package/dist/clients/ReadOnlyClient.d.ts.map +1 -0
- package/dist/clients/ReadOnlyClient.js +141 -0
- package/dist/clients/ValidationClient.d.ts +8 -0
- package/dist/clients/ValidationClient.d.ts.map +1 -0
- package/dist/clients/ValidationClient.js +14 -0
- package/dist/core/class/ClassBuilder.d.ts +140 -0
- package/dist/core/class/ClassBuilder.d.ts.map +1 -0
- package/dist/core/class/ClassBuilder.js +400 -0
- package/dist/core/class/activation.d.ts +11 -0
- package/dist/core/class/activation.d.ts.map +1 -0
- package/dist/core/class/activation.js +16 -0
- package/dist/core/class/check.d.ts +24 -0
- package/dist/core/class/check.d.ts.map +1 -0
- package/dist/core/class/check.js +73 -0
- package/dist/core/class/create.d.ts +30 -0
- package/dist/core/class/create.d.ts.map +1 -0
- package/dist/core/class/create.js +118 -0
- package/dist/core/class/index.d.ts +14 -0
- package/dist/core/class/index.d.ts.map +1 -0
- package/dist/core/class/index.js +31 -0
- package/dist/core/class/lock.d.ts +20 -0
- package/dist/core/class/lock.d.ts.map +1 -0
- package/dist/core/class/lock.js +49 -0
- package/dist/core/class/read.d.ts +34 -0
- package/dist/core/class/read.d.ts.map +1 -0
- package/dist/core/class/read.js +59 -0
- package/dist/core/class/run.d.ts +51 -0
- package/dist/core/class/run.d.ts.map +1 -0
- package/dist/core/class/run.js +105 -0
- package/dist/core/class/unlock.d.ts +11 -0
- package/dist/core/class/unlock.d.ts.map +1 -0
- package/dist/core/class/unlock.js +16 -0
- package/dist/core/class/update.d.ts +11 -0
- package/dist/core/class/update.d.ts.map +1 -0
- package/dist/core/class/update.js +30 -0
- package/dist/core/class/validation.d.ts +28 -0
- package/dist/core/class/validation.d.ts.map +1 -0
- package/dist/core/class/validation.js +269 -0
- package/dist/core/dataElement/DataElementBuilder.d.ts +113 -0
- package/dist/core/dataElement/DataElementBuilder.d.ts.map +1 -0
- package/dist/core/dataElement/DataElementBuilder.js +449 -0
- package/dist/core/dataElement/activation.d.ts +11 -0
- package/dist/core/dataElement/activation.d.ts.map +1 -0
- package/dist/core/dataElement/activation.js +123 -0
- package/dist/core/dataElement/check.d.ts +12 -0
- package/dist/core/dataElement/check.d.ts.map +1 -0
- package/dist/core/dataElement/check.js +32 -0
- package/dist/core/dataElement/create.d.ts +12 -0
- package/dist/core/dataElement/create.d.ts.map +1 -0
- package/dist/core/dataElement/create.js +259 -0
- package/dist/core/dataElement/delete.d.ts +14 -0
- package/dist/core/dataElement/delete.d.ts.map +1 -0
- package/dist/core/dataElement/delete.js +21 -0
- package/dist/core/dataElement/index.d.ts +14 -0
- package/dist/core/dataElement/index.d.ts.map +1 -0
- package/dist/core/dataElement/index.js +31 -0
- package/dist/core/dataElement/lock.d.ts +10 -0
- package/dist/core/dataElement/lock.d.ts.map +1 -0
- package/dist/core/dataElement/lock.js +31 -0
- package/dist/core/dataElement/read.d.ts +17 -0
- package/dist/core/dataElement/read.d.ts.map +1 -0
- package/dist/core/dataElement/read.js +42 -0
- package/dist/core/dataElement/types.d.ts +64 -0
- package/dist/core/dataElement/types.d.ts.map +1 -0
- package/dist/core/dataElement/types.js +5 -0
- package/dist/core/dataElement/unlock.d.ts +11 -0
- package/dist/core/dataElement/unlock.d.ts.map +1 -0
- package/dist/core/dataElement/unlock.js +17 -0
- package/dist/core/dataElement/update.d.ts +29 -0
- package/dist/core/dataElement/update.d.ts.map +1 -0
- package/dist/core/dataElement/update.js +269 -0
- package/dist/core/delete.d.ts +22 -0
- package/dist/core/delete.d.ts.map +1 -0
- package/dist/core/delete.js +148 -0
- package/dist/core/domain/DomainBuilder.d.ts +135 -0
- package/dist/core/domain/DomainBuilder.d.ts.map +1 -0
- package/dist/core/domain/DomainBuilder.js +430 -0
- package/dist/core/domain/activation.d.ts +11 -0
- package/dist/core/domain/activation.d.ts.map +1 -0
- package/dist/core/domain/activation.js +16 -0
- package/dist/core/domain/check.d.ts +16 -0
- package/dist/core/domain/check.d.ts.map +1 -0
- package/dist/core/domain/check.js +36 -0
- package/dist/core/domain/create.d.ts +21 -0
- package/dist/core/domain/create.d.ts.map +1 -0
- package/dist/core/domain/create.js +172 -0
- package/dist/core/domain/delete.d.ts +14 -0
- package/dist/core/domain/delete.d.ts.map +1 -0
- package/dist/core/domain/delete.js +21 -0
- package/dist/core/domain/index.d.ts +14 -0
- package/dist/core/domain/index.d.ts.map +1 -0
- package/dist/core/domain/index.js +31 -0
- package/dist/core/domain/lock.d.ts +15 -0
- package/dist/core/domain/lock.d.ts.map +1 -0
- package/dist/core/domain/lock.js +61 -0
- package/dist/core/domain/read.d.ts +17 -0
- package/dist/core/domain/read.d.ts.map +1 -0
- package/dist/core/domain/read.js +42 -0
- package/dist/core/domain/types.d.ts +38 -0
- package/dist/core/domain/types.d.ts.map +1 -0
- package/dist/core/domain/types.js +5 -0
- package/dist/core/domain/unlock.d.ts +11 -0
- package/dist/core/domain/unlock.d.ts.map +1 -0
- package/dist/core/domain/unlock.js +17 -0
- package/dist/core/domain/update.d.ts +12 -0
- package/dist/core/domain/update.d.ts.map +1 -0
- package/dist/core/domain/update.js +144 -0
- package/dist/core/functionGroup/FunctionGroupBuilder.d.ts +91 -0
- package/dist/core/functionGroup/FunctionGroupBuilder.d.ts.map +1 -0
- package/dist/core/functionGroup/FunctionGroupBuilder.js +268 -0
- package/dist/core/functionGroup/activation.d.ts +10 -0
- package/dist/core/functionGroup/activation.d.ts.map +1 -0
- package/dist/core/functionGroup/activation.js +30 -0
- package/dist/core/functionGroup/check.d.ts +24 -0
- package/dist/core/functionGroup/check.d.ts.map +1 -0
- package/dist/core/functionGroup/check.js +91 -0
- package/dist/core/functionGroup/create.d.ts +12 -0
- package/dist/core/functionGroup/create.d.ts.map +1 -0
- package/dist/core/functionGroup/create.js +90 -0
- package/dist/core/functionGroup/delete.d.ts +14 -0
- package/dist/core/functionGroup/delete.d.ts.map +1 -0
- package/dist/core/functionGroup/delete.js +21 -0
- package/dist/core/functionGroup/index.d.ts +15 -0
- package/dist/core/functionGroup/index.d.ts.map +1 -0
- package/dist/core/functionGroup/index.js +32 -0
- package/dist/core/functionGroup/lock.d.ts +25 -0
- package/dist/core/functionGroup/lock.d.ts.map +1 -0
- package/dist/core/functionGroup/lock.js +50 -0
- package/dist/core/functionGroup/read.d.ts +17 -0
- package/dist/core/functionGroup/read.d.ts.map +1 -0
- package/dist/core/functionGroup/read.js +42 -0
- package/dist/core/functionGroup/types.d.ts +11 -0
- package/dist/core/functionGroup/types.d.ts.map +1 -0
- package/dist/core/functionGroup/types.js +5 -0
- package/dist/core/functionGroup/unlock.d.ts +5 -0
- package/dist/core/functionGroup/unlock.d.ts.map +1 -0
- package/dist/core/functionGroup/unlock.js +8 -0
- package/dist/core/functionGroup/update.d.ts +20 -0
- package/dist/core/functionGroup/update.d.ts.map +1 -0
- package/dist/core/functionGroup/update.js +119 -0
- package/dist/core/functionGroup/validation.d.ts +10 -0
- package/dist/core/functionGroup/validation.d.ts.map +1 -0
- package/dist/core/functionGroup/validation.js +17 -0
- package/dist/core/functionModule/FunctionModuleBuilder.d.ts +101 -0
- package/dist/core/functionModule/FunctionModuleBuilder.d.ts.map +1 -0
- package/dist/core/functionModule/FunctionModuleBuilder.js +314 -0
- package/dist/core/functionModule/activation.d.ts +10 -0
- package/dist/core/functionModule/activation.d.ts.map +1 -0
- package/dist/core/functionModule/activation.js +17 -0
- package/dist/core/functionModule/check.d.ts +23 -0
- package/dist/core/functionModule/check.d.ts.map +1 -0
- package/dist/core/functionModule/check.js +116 -0
- package/dist/core/functionModule/create.d.ts +12 -0
- package/dist/core/functionModule/create.d.ts.map +1 -0
- package/dist/core/functionModule/create.js +158 -0
- package/dist/core/functionModule/delete.d.ts +15 -0
- package/dist/core/functionModule/delete.d.ts.map +1 -0
- package/dist/core/functionModule/delete.js +25 -0
- package/dist/core/functionModule/index.d.ts +15 -0
- package/dist/core/functionModule/index.d.ts.map +1 -0
- package/dist/core/functionModule/index.js +32 -0
- package/dist/core/functionModule/lock.d.ts +18 -0
- package/dist/core/functionModule/lock.d.ts.map +1 -0
- package/dist/core/functionModule/lock.js +52 -0
- package/dist/core/functionModule/read.d.ts +31 -0
- package/dist/core/functionModule/read.d.ts.map +1 -0
- package/dist/core/functionModule/read.js +57 -0
- package/dist/core/functionModule/types.d.ts +19 -0
- package/dist/core/functionModule/types.d.ts.map +1 -0
- package/dist/core/functionModule/types.js +5 -0
- package/dist/core/functionModule/unlock.d.ts +10 -0
- package/dist/core/functionModule/unlock.d.ts.map +1 -0
- package/dist/core/functionModule/unlock.js +20 -0
- package/dist/core/functionModule/update.d.ts +17 -0
- package/dist/core/functionModule/update.d.ts.map +1 -0
- package/dist/core/functionModule/update.js +103 -0
- package/dist/core/functionModule/validation.d.ts +27 -0
- package/dist/core/functionModule/validation.d.ts.map +1 -0
- package/dist/core/functionModule/validation.js +107 -0
- package/dist/core/interface/InterfaceBuilder.d.ts +98 -0
- package/dist/core/interface/InterfaceBuilder.d.ts.map +1 -0
- package/dist/core/interface/InterfaceBuilder.js +311 -0
- package/dist/core/interface/activation.d.ts +11 -0
- package/dist/core/interface/activation.d.ts.map +1 -0
- package/dist/core/interface/activation.js +16 -0
- package/dist/core/interface/check.d.ts +10 -0
- package/dist/core/interface/check.d.ts.map +1 -0
- package/dist/core/interface/check.js +18 -0
- package/dist/core/interface/create.d.ts +12 -0
- package/dist/core/interface/create.d.ts.map +1 -0
- package/dist/core/interface/create.js +119 -0
- package/dist/core/interface/delete.d.ts +20 -0
- package/dist/core/interface/delete.d.ts.map +1 -0
- package/dist/core/interface/delete.js +47 -0
- package/dist/core/interface/index.d.ts +15 -0
- package/dist/core/interface/index.d.ts.map +1 -0
- package/dist/core/interface/index.js +32 -0
- package/dist/core/interface/lock.d.ts +23 -0
- package/dist/core/interface/lock.d.ts.map +1 -0
- package/dist/core/interface/lock.js +51 -0
- package/dist/core/interface/read.d.ts +26 -0
- package/dist/core/interface/read.d.ts.map +1 -0
- package/dist/core/interface/read.js +51 -0
- package/dist/core/interface/types.d.ts +19 -0
- package/dist/core/interface/types.d.ts.map +1 -0
- package/dist/core/interface/types.js +5 -0
- package/dist/core/interface/unlock.d.ts +11 -0
- package/dist/core/interface/unlock.d.ts.map +1 -0
- package/dist/core/interface/unlock.js +35 -0
- package/dist/core/interface/update.d.ts +12 -0
- package/dist/core/interface/update.d.ts.map +1 -0
- package/dist/core/interface/update.js +82 -0
- package/dist/core/interface/validation.d.ts +10 -0
- package/dist/core/interface/validation.d.ts.map +1 -0
- package/dist/core/interface/validation.js +17 -0
- package/dist/core/managementOperations.d.ts +34 -0
- package/dist/core/managementOperations.d.ts.map +1 -0
- package/dist/core/managementOperations.js +136 -0
- package/dist/core/package/PackageBuilder.d.ts +129 -0
- package/dist/core/package/PackageBuilder.d.ts.map +1 -0
- package/dist/core/package/PackageBuilder.js +386 -0
- package/dist/core/package/check.d.ts +9 -0
- package/dist/core/package/check.d.ts.map +1 -0
- package/dist/core/package/check.js +29 -0
- package/dist/core/package/create.d.ts +12 -0
- package/dist/core/package/create.d.ts.map +1 -0
- package/dist/core/package/create.js +145 -0
- package/dist/core/package/delete.d.ts +27 -0
- package/dist/core/package/delete.d.ts.map +1 -0
- package/dist/core/package/delete.js +138 -0
- package/dist/core/package/index.d.ts +15 -0
- package/dist/core/package/index.d.ts.map +1 -0
- package/dist/core/package/index.js +32 -0
- package/dist/core/package/lock.d.ts +10 -0
- package/dist/core/package/lock.d.ts.map +1 -0
- package/dist/core/package/lock.js +28 -0
- package/dist/core/package/read.d.ts +17 -0
- package/dist/core/package/read.d.ts.map +1 -0
- package/dist/core/package/read.js +42 -0
- package/dist/core/package/transportCheck.d.ts +10 -0
- package/dist/core/package/transportCheck.d.ts.map +1 -0
- package/dist/core/package/transportCheck.js +52 -0
- package/dist/core/package/types.d.ts +15 -0
- package/dist/core/package/types.d.ts.map +1 -0
- package/dist/core/package/types.js +5 -0
- package/dist/core/package/unlock.d.ts +11 -0
- package/dist/core/package/unlock.d.ts.map +1 -0
- package/dist/core/package/unlock.js +16 -0
- package/dist/core/package/update.d.ts +19 -0
- package/dist/core/package/update.d.ts.map +1 -0
- package/dist/core/package/update.js +125 -0
- package/dist/core/package/validation.d.ts +14 -0
- package/dist/core/package/validation.d.ts.map +1 -0
- package/dist/core/package/validation.js +72 -0
- package/dist/core/program/ProgramBuilder.d.ts +102 -0
- package/dist/core/program/ProgramBuilder.d.ts.map +1 -0
- package/dist/core/program/ProgramBuilder.js +321 -0
- package/dist/core/program/activation.d.ts +11 -0
- package/dist/core/program/activation.d.ts.map +1 -0
- package/dist/core/program/activation.js +16 -0
- package/dist/core/program/check.d.ts +10 -0
- package/dist/core/program/check.d.ts.map +1 -0
- package/dist/core/program/check.js +18 -0
- package/dist/core/program/create.d.ts +23 -0
- package/dist/core/program/create.d.ts.map +1 -0
- package/dist/core/program/create.js +159 -0
- package/dist/core/program/delete.d.ts +14 -0
- package/dist/core/program/delete.d.ts.map +1 -0
- package/dist/core/program/delete.js +21 -0
- package/dist/core/program/index.d.ts +14 -0
- package/dist/core/program/index.d.ts.map +1 -0
- package/dist/core/program/index.js +31 -0
- package/dist/core/program/lock.d.ts +20 -0
- package/dist/core/program/lock.d.ts.map +1 -0
- package/dist/core/program/lock.js +49 -0
- package/dist/core/program/read.d.ts +26 -0
- package/dist/core/program/read.d.ts.map +1 -0
- package/dist/core/program/read.js +51 -0
- package/dist/core/program/unlock.d.ts +11 -0
- package/dist/core/program/unlock.d.ts.map +1 -0
- package/dist/core/program/unlock.js +16 -0
- package/dist/core/program/update.d.ts +16 -0
- package/dist/core/program/update.d.ts.map +1 -0
- package/dist/core/program/update.js +82 -0
- package/dist/core/program/validation.d.ts +10 -0
- package/dist/core/program/validation.d.ts.map +1 -0
- package/dist/core/program/validation.js +17 -0
- package/dist/core/readOperations.d.ts +63 -0
- package/dist/core/readOperations.d.ts.map +1 -0
- package/dist/core/readOperations.js +204 -0
- package/dist/core/shared/checkRun.d.ts +68 -0
- package/dist/core/shared/checkRun.d.ts.map +1 -0
- package/dist/core/shared/checkRun.js +292 -0
- package/dist/core/shared/readMetadata.d.ts +16 -0
- package/dist/core/shared/readMetadata.d.ts.map +1 -0
- package/dist/core/shared/readMetadata.js +74 -0
- package/dist/core/shared/readSource.d.ts +21 -0
- package/dist/core/shared/readSource.d.ts.map +1 -0
- package/dist/core/shared/readSource.js +83 -0
- package/dist/core/shared/search.d.ts +26 -0
- package/dist/core/shared/search.d.ts.map +1 -0
- package/dist/core/shared/search.js +32 -0
- package/dist/core/shared/sqlQuery.d.ts +22 -0
- package/dist/core/shared/sqlQuery.d.ts.map +1 -0
- package/dist/core/shared/sqlQuery.js +36 -0
- package/dist/core/shared/systemInfo.d.ts +22 -0
- package/dist/core/shared/systemInfo.d.ts.map +1 -0
- package/dist/core/shared/systemInfo.js +67 -0
- package/dist/core/shared/tableContents.d.ts +22 -0
- package/dist/core/shared/tableContents.d.ts.map +1 -0
- package/dist/core/shared/tableContents.js +89 -0
- package/dist/core/shared/validation.d.ts +26 -0
- package/dist/core/shared/validation.d.ts.map +1 -0
- package/dist/core/shared/validation.js +134 -0
- package/dist/core/shared/whereUsed.d.ts +19 -0
- package/dist/core/shared/whereUsed.d.ts.map +1 -0
- package/dist/core/shared/whereUsed.js +88 -0
- package/dist/core/structure/StructureBuilder.d.ts +124 -0
- package/dist/core/structure/StructureBuilder.d.ts.map +1 -0
- package/dist/core/structure/StructureBuilder.js +357 -0
- package/dist/core/structure/activation.d.ts +10 -0
- package/dist/core/structure/activation.d.ts.map +1 -0
- package/dist/core/structure/activation.js +15 -0
- package/dist/core/structure/check.d.ts +12 -0
- package/dist/core/structure/check.d.ts.map +1 -0
- package/dist/core/structure/check.js +44 -0
- package/dist/core/structure/create.d.ts +12 -0
- package/dist/core/structure/create.d.ts.map +1 -0
- package/dist/core/structure/create.js +136 -0
- package/dist/core/structure/delete.d.ts +14 -0
- package/dist/core/structure/delete.d.ts.map +1 -0
- package/dist/core/structure/delete.js +21 -0
- package/dist/core/structure/index.d.ts +15 -0
- package/dist/core/structure/index.d.ts.map +1 -0
- package/dist/core/structure/index.js +32 -0
- package/dist/core/structure/lock.d.ts +10 -0
- package/dist/core/structure/lock.d.ts.map +1 -0
- package/dist/core/structure/lock.js +28 -0
- package/dist/core/structure/read.d.ts +26 -0
- package/dist/core/structure/read.d.ts.map +1 -0
- package/dist/core/structure/read.js +51 -0
- package/dist/core/structure/types.d.ts +33 -0
- package/dist/core/structure/types.d.ts.map +1 -0
- package/dist/core/structure/types.js +5 -0
- package/dist/core/structure/unlock.d.ts +11 -0
- package/dist/core/structure/unlock.d.ts.map +1 -0
- package/dist/core/structure/unlock.js +16 -0
- package/dist/core/structure/update.d.ts +11 -0
- package/dist/core/structure/update.d.ts.map +1 -0
- package/dist/core/structure/update.js +26 -0
- package/dist/core/structure/validation.d.ts +10 -0
- package/dist/core/structure/validation.d.ts.map +1 -0
- package/dist/core/structure/validation.js +17 -0
- package/dist/core/table/TableBuilder.d.ts +115 -0
- package/dist/core/table/TableBuilder.d.ts.map +1 -0
- package/dist/core/table/TableBuilder.js +328 -0
- package/dist/core/table/activation.d.ts +10 -0
- package/dist/core/table/activation.d.ts.map +1 -0
- package/dist/core/table/activation.js +15 -0
- package/dist/core/table/check.d.ts +11 -0
- package/dist/core/table/check.d.ts.map +1 -0
- package/dist/core/table/check.js +30 -0
- package/dist/core/table/create.d.ts +12 -0
- package/dist/core/table/create.d.ts.map +1 -0
- package/dist/core/table/create.js +182 -0
- package/dist/core/table/delete.d.ts +14 -0
- package/dist/core/table/delete.d.ts.map +1 -0
- package/dist/core/table/delete.js +21 -0
- package/dist/core/table/index.d.ts +15 -0
- package/dist/core/table/index.d.ts.map +1 -0
- package/dist/core/table/index.js +32 -0
- package/dist/core/table/lock.d.ts +9 -0
- package/dist/core/table/lock.d.ts.map +1 -0
- package/dist/core/table/lock.js +29 -0
- package/dist/core/table/read.d.ts +26 -0
- package/dist/core/table/read.d.ts.map +1 -0
- package/dist/core/table/read.js +51 -0
- package/dist/core/table/types.d.ts +10 -0
- package/dist/core/table/types.d.ts.map +1 -0
- package/dist/core/table/types.js +5 -0
- package/dist/core/table/unlock.d.ts +15 -0
- package/dist/core/table/unlock.d.ts.map +1 -0
- package/dist/core/table/unlock.js +32 -0
- package/dist/core/table/update.d.ts +16 -0
- package/dist/core/table/update.d.ts.map +1 -0
- package/dist/core/table/update.js +32 -0
- package/dist/core/table/validation.d.ts +10 -0
- package/dist/core/table/validation.d.ts.map +1 -0
- package/dist/core/table/validation.js +17 -0
- package/dist/core/transport/TransportBuilder.d.ts +85 -0
- package/dist/core/transport/TransportBuilder.d.ts.map +1 -0
- package/dist/core/transport/TransportBuilder.js +154 -0
- package/dist/core/transport/create.d.ts +11 -0
- package/dist/core/transport/create.d.ts.map +1 -0
- package/dist/core/transport/create.js +157 -0
- package/dist/core/transport/index.d.ts +8 -0
- package/dist/core/transport/index.d.ts.map +1 -0
- package/dist/core/transport/index.js +25 -0
- package/dist/core/transport/read.d.ts +10 -0
- package/dist/core/transport/read.d.ts.map +1 -0
- package/dist/core/transport/read.js +22 -0
- package/dist/core/transport/types.d.ts +10 -0
- package/dist/core/transport/types.d.ts.map +1 -0
- package/dist/core/transport/types.js +5 -0
- package/dist/core/view/ViewBuilder.d.ts +117 -0
- package/dist/core/view/ViewBuilder.d.ts.map +1 -0
- package/dist/core/view/ViewBuilder.js +335 -0
- package/dist/core/view/activation.d.ts +10 -0
- package/dist/core/view/activation.d.ts.map +1 -0
- package/dist/core/view/activation.js +15 -0
- package/dist/core/view/check.d.ts +7 -0
- package/dist/core/view/check.d.ts.map +1 -0
- package/dist/core/view/check.js +57 -0
- package/dist/core/view/create.d.ts +12 -0
- package/dist/core/view/create.d.ts.map +1 -0
- package/dist/core/view/create.js +88 -0
- package/dist/core/view/delete.d.ts +14 -0
- package/dist/core/view/delete.d.ts.map +1 -0
- package/dist/core/view/delete.js +21 -0
- package/dist/core/view/index.d.ts +15 -0
- package/dist/core/view/index.d.ts.map +1 -0
- package/dist/core/view/index.js +32 -0
- package/dist/core/view/lock.d.ts +18 -0
- package/dist/core/view/lock.d.ts.map +1 -0
- package/dist/core/view/lock.js +45 -0
- package/dist/core/view/read.d.ts +26 -0
- package/dist/core/view/read.d.ts.map +1 -0
- package/dist/core/view/read.js +51 -0
- package/dist/core/view/types.d.ts +19 -0
- package/dist/core/view/types.d.ts.map +1 -0
- package/dist/core/view/types.js +5 -0
- package/dist/core/view/unlock.d.ts +10 -0
- package/dist/core/view/unlock.d.ts.map +1 -0
- package/dist/core/view/unlock.js +15 -0
- package/dist/core/view/update.d.ts +12 -0
- package/dist/core/view/update.d.ts.map +1 -0
- package/dist/core/view/update.js +89 -0
- package/dist/core/view/validation.d.ts +10 -0
- package/dist/core/view/validation.d.ts.map +1 -0
- package/dist/core/view/validation.js +17 -0
- package/dist/core.d.ts +133 -0
- package/dist/core.d.ts.map +1 -0
- package/dist/core.js +175 -0
- package/dist/index.d.ts +38 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +60 -0
- package/dist/utils/activationUtils.d.ts +44 -0
- package/dist/utils/activationUtils.d.ts.map +1 -0
- package/dist/utils/activationUtils.js +127 -0
- package/dist/utils/internalUtils.d.ts +12 -0
- package/dist/utils/internalUtils.d.ts.map +1 -0
- package/dist/utils/internalUtils.js +16 -0
- package/dist/utils/lockStateManager.d.ts +64 -0
- package/dist/utils/lockStateManager.d.ts.map +1 -0
- package/dist/utils/lockStateManager.js +172 -0
- package/dist/utils/sessionUtils.d.ts +69 -0
- package/dist/utils/sessionUtils.d.ts.map +1 -0
- package/dist/utils/sessionUtils.js +134 -0
- package/package.json +75 -0
|
@@ -0,0 +1,400 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* ClassBuilder - Fluent API for class operations with Promise chaining
|
|
4
|
+
*
|
|
5
|
+
* Supports:
|
|
6
|
+
* - Method chaining: builder.validate().then(b => b.create()).then(b => b.lock())...
|
|
7
|
+
* - Error handling: .catch() for error callbacks
|
|
8
|
+
* - Cleanup: .finally() for guaranteed execution
|
|
9
|
+
* - Result storage: all results stored in logger/state
|
|
10
|
+
* - Chain interruption: chain stops on first error (standard Promise behavior)
|
|
11
|
+
*
|
|
12
|
+
* @example
|
|
13
|
+
* ```typescript
|
|
14
|
+
* const builder = new ClassBuilder(connection, logger, {
|
|
15
|
+
* className: 'ZCL_TEST',
|
|
16
|
+
* packageName: 'ZOK_TEST_PKG_01'
|
|
17
|
+
* })
|
|
18
|
+
* .setCode('CLASS ZCL_TEST DEFINITION...');
|
|
19
|
+
*
|
|
20
|
+
* await builder
|
|
21
|
+
* .validate()
|
|
22
|
+
* .then(b => b.create())
|
|
23
|
+
* .then(b => b.lock())
|
|
24
|
+
* .then(b => b.update())
|
|
25
|
+
* .then(b => b.check())
|
|
26
|
+
* .then(b => b.unlock())
|
|
27
|
+
* .then(b => b.activate())
|
|
28
|
+
* .catch(error => {
|
|
29
|
+
* logger.error('Operation failed:', error);
|
|
30
|
+
* // Handle error
|
|
31
|
+
* })
|
|
32
|
+
* .finally(() => {
|
|
33
|
+
* // Cleanup - always executes
|
|
34
|
+
* });
|
|
35
|
+
* ```
|
|
36
|
+
*/
|
|
37
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
38
|
+
exports.ClassBuilder = void 0;
|
|
39
|
+
const sessionUtils_1 = require("../../utils/sessionUtils");
|
|
40
|
+
const validation_1 = require("./validation");
|
|
41
|
+
const create_1 = require("./create");
|
|
42
|
+
const read_1 = require("./read");
|
|
43
|
+
const lock_1 = require("./lock");
|
|
44
|
+
const update_1 = require("./update");
|
|
45
|
+
const check_1 = require("./check");
|
|
46
|
+
const unlock_1 = require("./unlock");
|
|
47
|
+
const activation_1 = require("./activation");
|
|
48
|
+
class ClassBuilder {
|
|
49
|
+
connection;
|
|
50
|
+
logger;
|
|
51
|
+
config;
|
|
52
|
+
sourceCode;
|
|
53
|
+
lockHandle;
|
|
54
|
+
sessionId;
|
|
55
|
+
state;
|
|
56
|
+
constructor(connection, logger, config) {
|
|
57
|
+
this.connection = connection;
|
|
58
|
+
this.logger = logger;
|
|
59
|
+
this.config = { ...config };
|
|
60
|
+
this.sessionId = config.sessionId || (0, sessionUtils_1.generateSessionId)();
|
|
61
|
+
this.state = {
|
|
62
|
+
errors: []
|
|
63
|
+
};
|
|
64
|
+
}
|
|
65
|
+
// Builder methods - return this for chaining
|
|
66
|
+
setPackage(packageName) {
|
|
67
|
+
this.config.packageName = packageName;
|
|
68
|
+
this.logger.debug?.('Package set:', packageName);
|
|
69
|
+
return this;
|
|
70
|
+
}
|
|
71
|
+
setRequest(transportRequest) {
|
|
72
|
+
this.config.transportRequest = transportRequest;
|
|
73
|
+
this.logger.debug?.('Transport request set:', transportRequest);
|
|
74
|
+
return this;
|
|
75
|
+
}
|
|
76
|
+
setName(className) {
|
|
77
|
+
this.config.className = className;
|
|
78
|
+
this.logger.debug?.('Class name set:', className);
|
|
79
|
+
return this;
|
|
80
|
+
}
|
|
81
|
+
setCode(sourceCode) {
|
|
82
|
+
this.sourceCode = sourceCode;
|
|
83
|
+
this.logger.debug?.('Source code set, length:', sourceCode.length);
|
|
84
|
+
return this;
|
|
85
|
+
}
|
|
86
|
+
setDescription(description) {
|
|
87
|
+
this.config.description = description;
|
|
88
|
+
return this;
|
|
89
|
+
}
|
|
90
|
+
setSuperclass(superclass) {
|
|
91
|
+
this.config.superclass = superclass;
|
|
92
|
+
return this;
|
|
93
|
+
}
|
|
94
|
+
setFinal(final) {
|
|
95
|
+
this.config.final = final;
|
|
96
|
+
return this;
|
|
97
|
+
}
|
|
98
|
+
setAbstract(abstract) {
|
|
99
|
+
this.config.abstract = abstract;
|
|
100
|
+
return this;
|
|
101
|
+
}
|
|
102
|
+
setCreateProtected(createProtected) {
|
|
103
|
+
this.config.createProtected = createProtected;
|
|
104
|
+
return this;
|
|
105
|
+
}
|
|
106
|
+
// Operation methods - return Promise<this> for Promise chaining
|
|
107
|
+
// Chain is interrupted on error (standard Promise behavior)
|
|
108
|
+
async validate() {
|
|
109
|
+
try {
|
|
110
|
+
this.logger.info?.('Validating class:', this.config.className);
|
|
111
|
+
const result = await (0, validation_1.validateClassName)(this.connection, this.config.className, this.config.packageName, this.config.description, this.config.superclass);
|
|
112
|
+
this.state.validationResult = result;
|
|
113
|
+
this.logger.info?.('Validation successful:', result.valid);
|
|
114
|
+
return this;
|
|
115
|
+
}
|
|
116
|
+
catch (error) {
|
|
117
|
+
this.state.errors.push({
|
|
118
|
+
method: 'validate',
|
|
119
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
120
|
+
timestamp: new Date()
|
|
121
|
+
});
|
|
122
|
+
this.logger.error?.('Validation failed:', error);
|
|
123
|
+
throw error; // Interrupts chain
|
|
124
|
+
}
|
|
125
|
+
}
|
|
126
|
+
async create() {
|
|
127
|
+
try {
|
|
128
|
+
if (!this.config.packageName) {
|
|
129
|
+
throw new Error('Package name is required');
|
|
130
|
+
}
|
|
131
|
+
this.logger.info?.('Creating class:', this.config.className);
|
|
132
|
+
const result = await (0, create_1.createClass)(this.connection, {
|
|
133
|
+
class_name: this.config.className,
|
|
134
|
+
package_name: this.config.packageName,
|
|
135
|
+
transport_request: this.config.transportRequest,
|
|
136
|
+
description: this.config.description,
|
|
137
|
+
superclass: this.config.superclass,
|
|
138
|
+
final: this.config.final,
|
|
139
|
+
abstract: this.config.abstract,
|
|
140
|
+
create_protected: this.config.createProtected,
|
|
141
|
+
master_system: this.config.masterSystem,
|
|
142
|
+
responsible: this.config.responsible,
|
|
143
|
+
});
|
|
144
|
+
this.state.createResult = result;
|
|
145
|
+
this.logger.info?.('Class created successfully:', result.status);
|
|
146
|
+
return this;
|
|
147
|
+
}
|
|
148
|
+
catch (error) {
|
|
149
|
+
this.state.errors.push({
|
|
150
|
+
method: 'create',
|
|
151
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
152
|
+
timestamp: new Date()
|
|
153
|
+
});
|
|
154
|
+
this.logger.error?.('Create failed:', error);
|
|
155
|
+
throw error; // Interrupts chain
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
async read(version = 'active') {
|
|
159
|
+
try {
|
|
160
|
+
this.logger.info?.('Reading class source:', this.config.className, 'version:', version);
|
|
161
|
+
const result = await (0, read_1.getClassSource)(this.connection, this.config.className, version);
|
|
162
|
+
this.state.readResult = result;
|
|
163
|
+
this.logger.info?.('Class source read successfully:', result.status, 'bytes:', result.data?.length || 0);
|
|
164
|
+
return this;
|
|
165
|
+
}
|
|
166
|
+
catch (error) {
|
|
167
|
+
this.state.errors.push({
|
|
168
|
+
method: 'read',
|
|
169
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
170
|
+
timestamp: new Date()
|
|
171
|
+
});
|
|
172
|
+
this.logger.error?.('Read failed:', {
|
|
173
|
+
className: this.config.className,
|
|
174
|
+
version,
|
|
175
|
+
status: error.response?.status,
|
|
176
|
+
statusText: error.response?.statusText,
|
|
177
|
+
data: error.response?.data,
|
|
178
|
+
message: error.message
|
|
179
|
+
});
|
|
180
|
+
throw error; // Interrupts chain
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
async readMetadata() {
|
|
184
|
+
try {
|
|
185
|
+
this.logger.info?.('Reading class metadata:', this.config.className);
|
|
186
|
+
const result = await (0, read_1.getClassMetadata)(this.connection, this.config.className);
|
|
187
|
+
this.state.metadataResult = result;
|
|
188
|
+
this.logger.info?.('Class metadata read successfully:', result.status);
|
|
189
|
+
return this;
|
|
190
|
+
}
|
|
191
|
+
catch (error) {
|
|
192
|
+
this.state.errors.push({
|
|
193
|
+
method: 'readMetadata',
|
|
194
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
195
|
+
timestamp: new Date()
|
|
196
|
+
});
|
|
197
|
+
this.logger.error?.('Read metadata failed:', error);
|
|
198
|
+
throw error; // Interrupts chain
|
|
199
|
+
}
|
|
200
|
+
}
|
|
201
|
+
async readTransport() {
|
|
202
|
+
try {
|
|
203
|
+
this.logger.info?.('Reading transport request for class:', this.config.className);
|
|
204
|
+
const result = await (0, read_1.getClassTransport)(this.connection, this.config.className);
|
|
205
|
+
this.state.transportResult = result;
|
|
206
|
+
this.logger.info?.('Transport request read successfully:', result.status);
|
|
207
|
+
return this;
|
|
208
|
+
}
|
|
209
|
+
catch (error) {
|
|
210
|
+
this.state.errors.push({
|
|
211
|
+
method: 'readTransport',
|
|
212
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
213
|
+
timestamp: new Date()
|
|
214
|
+
});
|
|
215
|
+
this.logger.error?.('Read transport failed:', error);
|
|
216
|
+
throw error; // Interrupts chain
|
|
217
|
+
}
|
|
218
|
+
}
|
|
219
|
+
async lock() {
|
|
220
|
+
try {
|
|
221
|
+
this.logger.info?.('Locking class:', this.config.className);
|
|
222
|
+
const lockHandle = await (0, lock_1.lockClass)(this.connection, this.config.className, this.sessionId);
|
|
223
|
+
this.lockHandle = lockHandle;
|
|
224
|
+
this.state.lockHandle = lockHandle;
|
|
225
|
+
// Register lock in persistent storage if callback provided
|
|
226
|
+
if (this.config.onLock) {
|
|
227
|
+
this.config.onLock(lockHandle, this.sessionId);
|
|
228
|
+
}
|
|
229
|
+
this.logger.info?.('Class locked, handle:', lockHandle.substring(0, 10) + '...');
|
|
230
|
+
return this;
|
|
231
|
+
}
|
|
232
|
+
catch (error) {
|
|
233
|
+
this.state.errors.push({
|
|
234
|
+
method: 'lock',
|
|
235
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
236
|
+
timestamp: new Date()
|
|
237
|
+
});
|
|
238
|
+
this.logger.error?.('Lock failed:', error);
|
|
239
|
+
throw error; // Interrupts chain
|
|
240
|
+
}
|
|
241
|
+
}
|
|
242
|
+
async update(sourceCode) {
|
|
243
|
+
try {
|
|
244
|
+
if (!this.lockHandle) {
|
|
245
|
+
throw new Error('Class must be locked before update. Call lock() first.');
|
|
246
|
+
}
|
|
247
|
+
const code = sourceCode || this.sourceCode;
|
|
248
|
+
if (!code) {
|
|
249
|
+
throw new Error('Source code is required. Use setCode() or pass as parameter.');
|
|
250
|
+
}
|
|
251
|
+
this.logger.info?.('Updating class source:', this.config.className);
|
|
252
|
+
const result = await (0, update_1.updateClass)(this.connection, this.config.className, code, this.lockHandle, this.sessionId, this.config.transportRequest);
|
|
253
|
+
this.state.updateResult = result;
|
|
254
|
+
this.logger.info?.('Class updated successfully:', result.status);
|
|
255
|
+
return this;
|
|
256
|
+
}
|
|
257
|
+
catch (error) {
|
|
258
|
+
this.state.errors.push({
|
|
259
|
+
method: 'update',
|
|
260
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
261
|
+
timestamp: new Date()
|
|
262
|
+
});
|
|
263
|
+
this.logger.error?.('Update failed:', error);
|
|
264
|
+
throw error; // Interrupts chain
|
|
265
|
+
}
|
|
266
|
+
}
|
|
267
|
+
async check(version = 'inactive') {
|
|
268
|
+
try {
|
|
269
|
+
this.logger.info?.('Checking class:', this.config.className, 'version:', version);
|
|
270
|
+
const result = await (0, check_1.checkClass)(this.connection, this.config.className, version, this.sourceCode, this.sessionId);
|
|
271
|
+
this.state.checkResult = result;
|
|
272
|
+
this.logger.info?.('Class check successful:', result.status);
|
|
273
|
+
return this;
|
|
274
|
+
}
|
|
275
|
+
catch (error) {
|
|
276
|
+
this.state.errors.push({
|
|
277
|
+
method: 'check',
|
|
278
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
279
|
+
timestamp: new Date()
|
|
280
|
+
});
|
|
281
|
+
this.logger.error?.('Check failed:', error);
|
|
282
|
+
throw error; // Interrupts chain
|
|
283
|
+
}
|
|
284
|
+
}
|
|
285
|
+
async unlock() {
|
|
286
|
+
try {
|
|
287
|
+
if (!this.lockHandle) {
|
|
288
|
+
throw new Error('Class is not locked. Call lock() first.');
|
|
289
|
+
}
|
|
290
|
+
this.logger.info?.('Unlocking class:', this.config.className);
|
|
291
|
+
const result = await (0, unlock_1.unlockClass)(this.connection, this.config.className, this.lockHandle, this.sessionId);
|
|
292
|
+
this.state.unlockResult = result;
|
|
293
|
+
this.lockHandle = undefined;
|
|
294
|
+
this.logger.info?.('Class unlocked successfully:', result.status);
|
|
295
|
+
return this;
|
|
296
|
+
}
|
|
297
|
+
catch (error) {
|
|
298
|
+
this.state.errors.push({
|
|
299
|
+
method: 'unlock',
|
|
300
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
301
|
+
timestamp: new Date()
|
|
302
|
+
});
|
|
303
|
+
this.logger.error?.('Unlock failed:', error);
|
|
304
|
+
throw error; // Interrupts chain
|
|
305
|
+
}
|
|
306
|
+
}
|
|
307
|
+
async activate() {
|
|
308
|
+
try {
|
|
309
|
+
this.logger.info?.('Activating class:', this.config.className);
|
|
310
|
+
const result = await (0, activation_1.activateClass)(this.connection, this.config.className, this.sessionId);
|
|
311
|
+
this.state.activateResult = result;
|
|
312
|
+
this.logger.info?.('Class activated successfully:', result.status);
|
|
313
|
+
return this;
|
|
314
|
+
}
|
|
315
|
+
catch (error) {
|
|
316
|
+
this.state.errors.push({
|
|
317
|
+
method: 'activate',
|
|
318
|
+
error: error instanceof Error ? error : new Error(String(error)),
|
|
319
|
+
timestamp: new Date()
|
|
320
|
+
});
|
|
321
|
+
this.logger.error?.('Activate failed:', error);
|
|
322
|
+
throw error; // Interrupts chain
|
|
323
|
+
}
|
|
324
|
+
}
|
|
325
|
+
async forceUnlock() {
|
|
326
|
+
if (!this.lockHandle) {
|
|
327
|
+
return;
|
|
328
|
+
}
|
|
329
|
+
try {
|
|
330
|
+
await (0, unlock_1.unlockClass)(this.connection, this.config.className, this.lockHandle, this.sessionId);
|
|
331
|
+
this.logger.info?.('Force unlock successful for', this.config.className);
|
|
332
|
+
}
|
|
333
|
+
catch (error) {
|
|
334
|
+
this.logger.warn?.('Force unlock failed:', error);
|
|
335
|
+
}
|
|
336
|
+
finally {
|
|
337
|
+
this.lockHandle = undefined;
|
|
338
|
+
this.state.lockHandle = undefined;
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
// Getters for accessing results
|
|
342
|
+
getState() {
|
|
343
|
+
return { ...this.state };
|
|
344
|
+
}
|
|
345
|
+
getValidationResult() {
|
|
346
|
+
return this.state.validationResult;
|
|
347
|
+
}
|
|
348
|
+
getCreateResult() {
|
|
349
|
+
return this.state.createResult;
|
|
350
|
+
}
|
|
351
|
+
getReadResult() {
|
|
352
|
+
return this.state.readResult;
|
|
353
|
+
}
|
|
354
|
+
getMetadataResult() {
|
|
355
|
+
return this.state.metadataResult;
|
|
356
|
+
}
|
|
357
|
+
getTransportResult() {
|
|
358
|
+
return this.state.transportResult;
|
|
359
|
+
}
|
|
360
|
+
getLockHandle() {
|
|
361
|
+
return this.lockHandle;
|
|
362
|
+
}
|
|
363
|
+
getUpdateResult() {
|
|
364
|
+
return this.state.updateResult;
|
|
365
|
+
}
|
|
366
|
+
getCheckResult() {
|
|
367
|
+
return this.state.checkResult;
|
|
368
|
+
}
|
|
369
|
+
getUnlockResult() {
|
|
370
|
+
return this.state.unlockResult;
|
|
371
|
+
}
|
|
372
|
+
getActivateResult() {
|
|
373
|
+
return this.state.activateResult;
|
|
374
|
+
}
|
|
375
|
+
getErrors() {
|
|
376
|
+
return [...this.state.errors];
|
|
377
|
+
}
|
|
378
|
+
getClassName() {
|
|
379
|
+
return this.config.className;
|
|
380
|
+
}
|
|
381
|
+
getSessionId() {
|
|
382
|
+
return this.sessionId;
|
|
383
|
+
}
|
|
384
|
+
// Helper method to get all results
|
|
385
|
+
getResults() {
|
|
386
|
+
return {
|
|
387
|
+
validation: this.state.validationResult,
|
|
388
|
+
create: this.state.createResult,
|
|
389
|
+
read: this.state.readResult,
|
|
390
|
+
metadata: this.state.metadataResult,
|
|
391
|
+
update: this.state.updateResult,
|
|
392
|
+
check: this.state.checkResult,
|
|
393
|
+
unlock: this.state.unlockResult,
|
|
394
|
+
activate: this.state.activateResult,
|
|
395
|
+
lockHandle: this.lockHandle,
|
|
396
|
+
errors: [...this.state.errors]
|
|
397
|
+
};
|
|
398
|
+
}
|
|
399
|
+
}
|
|
400
|
+
exports.ClassBuilder = ClassBuilder;
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Class activation operations
|
|
3
|
+
*/
|
|
4
|
+
import { AbapConnection } from '@mcp-abap-adt/connection';
|
|
5
|
+
import { AxiosResponse } from 'axios';
|
|
6
|
+
/**
|
|
7
|
+
* Activate class
|
|
8
|
+
* Makes class active and usable in SAP system
|
|
9
|
+
*/
|
|
10
|
+
export declare function activateClass(connection: AbapConnection, className: string, sessionId: string): Promise<AxiosResponse>;
|
|
11
|
+
//# sourceMappingURL=activation.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"activation.d.ts","sourceRoot":"","sources":["../../../src/core/class/activation.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAItC;;;GAGG;AACH,wBAAsB,aAAa,CACjC,UAAU,EAAE,cAAc,EAC1B,SAAS,EAAE,MAAM,EACjB,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,aAAa,CAAC,CAGxB"}
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Class activation operations
|
|
4
|
+
*/
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.activateClass = activateClass;
|
|
7
|
+
const internalUtils_1 = require("../../utils/internalUtils");
|
|
8
|
+
const activationUtils_1 = require("../../utils/activationUtils");
|
|
9
|
+
/**
|
|
10
|
+
* Activate class
|
|
11
|
+
* Makes class active and usable in SAP system
|
|
12
|
+
*/
|
|
13
|
+
async function activateClass(connection, className, sessionId) {
|
|
14
|
+
const objectUri = `/sap/bc/adt/oo/classes/${(0, internalUtils_1.encodeSapObjectName)(className).toLowerCase()}`;
|
|
15
|
+
return await (0, activationUtils_1.activateObjectInSession)(connection, objectUri, className, sessionId, true);
|
|
16
|
+
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Class check operations
|
|
3
|
+
*/
|
|
4
|
+
import { AbapConnection } from '@mcp-abap-adt/connection';
|
|
5
|
+
import { AxiosResponse } from 'axios';
|
|
6
|
+
/**
|
|
7
|
+
* Check class code (syntax, compilation, rules)
|
|
8
|
+
*
|
|
9
|
+
* CheckRun validates everything: syntax, compilation errors, warnings, code quality rules.
|
|
10
|
+
*
|
|
11
|
+
* Can check:
|
|
12
|
+
* - Existing active class: provide className, version='active', omit sourceCode
|
|
13
|
+
* - Existing inactive class: provide className, version='inactive', omit sourceCode
|
|
14
|
+
* - Hypothetical code: provide className, sourceCode, version (object doesn't need to exist)
|
|
15
|
+
*
|
|
16
|
+
* @param connection - SAP connection
|
|
17
|
+
* @param className - Class name
|
|
18
|
+
* @param version - 'active' (activated version) or 'inactive' (saved but not activated)
|
|
19
|
+
* @param sourceCode - Optional: source code to validate. If provided, validates hypothetical code without creating object
|
|
20
|
+
* @param sessionId - Optional session ID
|
|
21
|
+
* @returns Check result with errors/warnings
|
|
22
|
+
*/
|
|
23
|
+
export declare function checkClass(connection: AbapConnection, className: string, version: 'active' | 'inactive', sourceCode?: string, sessionId?: string): Promise<AxiosResponse>;
|
|
24
|
+
//# sourceMappingURL=check.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"check.d.ts","sourceRoot":"","sources":["../../../src/core/class/check.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAGtC;;;;;;;;;;;;;;;;GAgBG;AACH,wBAAsB,UAAU,CAC9B,UAAU,EAAE,cAAc,EAC1B,SAAS,EAAE,MAAM,EACjB,OAAO,EAAE,QAAQ,GAAG,UAAU,EAC9B,UAAU,CAAC,EAAE,MAAM,EACnB,SAAS,CAAC,EAAE,MAAM,GACjB,OAAO,CAAC,aAAa,CAAC,CAoBxB"}
|
|
@@ -0,0 +1,73 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
/**
|
|
3
|
+
* Class check operations
|
|
4
|
+
*/
|
|
5
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
6
|
+
if (k2 === undefined) k2 = k;
|
|
7
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
8
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
9
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
10
|
+
}
|
|
11
|
+
Object.defineProperty(o, k2, desc);
|
|
12
|
+
}) : (function(o, m, k, k2) {
|
|
13
|
+
if (k2 === undefined) k2 = k;
|
|
14
|
+
o[k2] = m[k];
|
|
15
|
+
}));
|
|
16
|
+
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
17
|
+
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
18
|
+
}) : function(o, v) {
|
|
19
|
+
o["default"] = v;
|
|
20
|
+
});
|
|
21
|
+
var __importStar = (this && this.__importStar) || (function () {
|
|
22
|
+
var ownKeys = function(o) {
|
|
23
|
+
ownKeys = Object.getOwnPropertyNames || function (o) {
|
|
24
|
+
var ar = [];
|
|
25
|
+
for (var k in o) if (Object.prototype.hasOwnProperty.call(o, k)) ar[ar.length] = k;
|
|
26
|
+
return ar;
|
|
27
|
+
};
|
|
28
|
+
return ownKeys(o);
|
|
29
|
+
};
|
|
30
|
+
return function (mod) {
|
|
31
|
+
if (mod && mod.__esModule) return mod;
|
|
32
|
+
var result = {};
|
|
33
|
+
if (mod != null) for (var k = ownKeys(mod), i = 0; i < k.length; i++) if (k[i] !== "default") __createBinding(result, mod, k[i]);
|
|
34
|
+
__setModuleDefault(result, mod);
|
|
35
|
+
return result;
|
|
36
|
+
};
|
|
37
|
+
})();
|
|
38
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
39
|
+
exports.checkClass = checkClass;
|
|
40
|
+
/**
|
|
41
|
+
* Check class code (syntax, compilation, rules)
|
|
42
|
+
*
|
|
43
|
+
* CheckRun validates everything: syntax, compilation errors, warnings, code quality rules.
|
|
44
|
+
*
|
|
45
|
+
* Can check:
|
|
46
|
+
* - Existing active class: provide className, version='active', omit sourceCode
|
|
47
|
+
* - Existing inactive class: provide className, version='inactive', omit sourceCode
|
|
48
|
+
* - Hypothetical code: provide className, sourceCode, version (object doesn't need to exist)
|
|
49
|
+
*
|
|
50
|
+
* @param connection - SAP connection
|
|
51
|
+
* @param className - Class name
|
|
52
|
+
* @param version - 'active' (activated version) or 'inactive' (saved but not activated)
|
|
53
|
+
* @param sourceCode - Optional: source code to validate. If provided, validates hypothetical code without creating object
|
|
54
|
+
* @param sessionId - Optional session ID
|
|
55
|
+
* @returns Check result with errors/warnings
|
|
56
|
+
*/
|
|
57
|
+
async function checkClass(connection, className, version, sourceCode, sessionId) {
|
|
58
|
+
const { runCheckRun, runCheckRunWithSource, parseCheckRunResponse } = await Promise.resolve().then(() => __importStar(require('../shared/checkRun')));
|
|
59
|
+
let response;
|
|
60
|
+
if (sourceCode) {
|
|
61
|
+
// Validate hypothetical code (object doesn't need to exist)
|
|
62
|
+
response = await runCheckRunWithSource(connection, 'class', className, sourceCode, version, 'abapCheckRun', sessionId);
|
|
63
|
+
}
|
|
64
|
+
else {
|
|
65
|
+
// Validate existing object in SAP (reads from system)
|
|
66
|
+
response = await runCheckRun(connection, 'class', className, version, 'abapCheckRun', sessionId);
|
|
67
|
+
}
|
|
68
|
+
const checkResult = parseCheckRunResponse(response);
|
|
69
|
+
if (!checkResult.success || checkResult.has_errors) {
|
|
70
|
+
throw new Error(`Class check failed: ${checkResult.message}`);
|
|
71
|
+
}
|
|
72
|
+
return response;
|
|
73
|
+
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Class create operations
|
|
3
|
+
*/
|
|
4
|
+
import { AbapConnection } from '@mcp-abap-adt/connection';
|
|
5
|
+
import { AxiosResponse } from 'axios';
|
|
6
|
+
export interface CreateClassParams {
|
|
7
|
+
class_name: string;
|
|
8
|
+
description?: string;
|
|
9
|
+
package_name: string;
|
|
10
|
+
transport_request?: string;
|
|
11
|
+
master_system?: string;
|
|
12
|
+
responsible?: string;
|
|
13
|
+
superclass?: string;
|
|
14
|
+
final?: boolean;
|
|
15
|
+
abstract?: boolean;
|
|
16
|
+
create_protected?: boolean;
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* Create ABAP class object (metadata only)
|
|
20
|
+
* Low-level function - only creates the class object with metadata
|
|
21
|
+
*
|
|
22
|
+
* To complete class creation workflow:
|
|
23
|
+
* 1. createClass() - create object
|
|
24
|
+
* 2. lockClass() - lock for modification
|
|
25
|
+
* 3. updateClass() - upload source code
|
|
26
|
+
* 4. unlockClass() - unlock
|
|
27
|
+
* 5. activateClass() - activate (optional)
|
|
28
|
+
*/
|
|
29
|
+
export declare function createClass(connection: AbapConnection, params: CreateClassParams): Promise<AxiosResponse>;
|
|
30
|
+
//# sourceMappingURL=create.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create.d.ts","sourceRoot":"","sources":["../../../src/core/class/create.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC1D,OAAO,EAAE,aAAa,EAAE,MAAM,OAAO,CAAC;AAWtC,MAAM,WAAW,iBAAiB;IAChC,UAAU,EAAE,MAAM,CAAC;IACnB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,YAAY,EAAE,MAAM,CAAC;IACrB,iBAAiB,CAAC,EAAE,MAAM,CAAC;IAC3B,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB,QAAQ,CAAC,EAAE,OAAO,CAAC;IACnB,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B;AAyFD;;;;;;;;;;GAUG;AACH,wBAAsB,WAAW,CAC/B,UAAU,EAAE,cAAc,EAC1B,MAAM,EAAE,iBAAiB,GACxB,OAAO,CAAC,aAAa,CAAC,CA4BxB"}
|