All Projects → SAP-samples → abap-platform-jak

SAP-samples / abap-platform-jak

Licence: Apache-2.0 license
The JSON ABAP Konverter

Programming Languages

ABAP
45 projects

Projects that are alternatives of or similar to abap-platform-jak

abap-odata-smoke-test
This ABAP Report performs simple smoke tests for activated ODATA services, providing basic automated testing for your ODATA endpoints.
Stars: ✭ 13 (-18.75%)
Mutual labels:  sample, abap, sample-code
teched2021-developer-keynote
SAP TechEd 2021 Developer Keynote: Improving Developers' Lives.
Stars: ✭ 23 (+43.75%)
Mutual labels:  sample, abap, sample-code
abap-alv-google-upload-sheet
Sample demonstrating export of ALV Grid data from SAP GUI directly to Google Drive and display exported data snapshots automatically in Google Sheets.
Stars: ✭ 24 (+50%)
Mutual labels:  sample, abap, sample-code
cloud-abap-rap
This repository contains several examples how to develop with the ABAP RESTful Application Programming Model (RAP) in SAP BTP, ABAP environment.
Stars: ✭ 98 (+512.5%)
Mutual labels:  sample, abap, sample-code
abap-exercises-codejam
Material for CodeJams on SAP Business Technology Platform, ABAP Environment and ABAP RESTful Application Programming Model.
Stars: ✭ 25 (+56.25%)
Mutual labels:  sample, abap, sample-code
hcp-portal-service-samples
Code samples of site and page templates, applications, widgets, shell plugins and more, intended to be used as references for development of custom content for SAP HANA Cloud Platform portal service sites.
Stars: ✭ 29 (+81.25%)
Mutual labels:  sample, sample-code
cloud-platform-iot-starterkit
This repository provides information and code for working with SAP Cloud Platform Internet of Things. It enables users to get an end-to-end IoT solution with either real hardware or simulators up and running fast and start their own extensions and usage based on this.
Stars: ✭ 276 (+1625%)
Mutual labels:  sample, sample-code
ui5-webcomponents-sample-vue
UI5 Web Components Sample TODO application built with Vue.
Stars: ✭ 52 (+225%)
Mutual labels:  sample, sample-code
cloud-bulletinboard-ads
This is the bulletinboard-ads sample application code used in the openSAP course: Cloud-Native Development with SAP Business Technology Platform (formerly SAP Cloud Platform).
Stars: ✭ 75 (+368.75%)
Mutual labels:  sample, sample-code
fiori-elements-feature-showcase
Sample application that demonstrates and documents a broad variety of features of SAP Fiori elements for OData V4. Developers can play around with the new features and learn how to implement them.
Stars: ✭ 76 (+375%)
Mutual labels:  sample, sample-code
cap-sflight
Using SAP Cloud Application Programming Model and SAP Fiori elements to build a simple travel management app, both with Node.js and Java.
Stars: ✭ 65 (+306.25%)
Mutual labels:  sample, sample-code
db2-samples
Db2 application code, configuration samples, and other examples
Stars: ✭ 56 (+250%)
Mutual labels:  sample, sample-code
hana-shine-xsa
SAP HANA Interactive Education for SAP HANA Extended Application Services, Advanced Model (SHINE for XS Advanced) is an education content to learn, develop, and deploy SAP HANA XS Advanced Model application and is a successor of SHINE for XS Classic.
Stars: ✭ 115 (+618.75%)
Mutual labels:  sample, sample-code
xf-application-mocks
Contains lightweight substitutes for SAP applications to ease the development and testing of extension and integration scenarios. In conjunction with SAP Business Technology Platform, kyma runtime, the efficient implementation of application extensions is supported without the need for real SAP applications being accessible during development.
Stars: ✭ 21 (+31.25%)
Mutual labels:  sample, sample-code
ui5-webcomponents-sample-angular
UI5 Web Components Sample TODO application built with Angular.
Stars: ✭ 34 (+112.5%)
Mutual labels:  sample, sample-code
ui5-service-worker-sample
ui5-service-worker-sample demonstrates how the Service Worker API, available in modern web browsers, could be used in a UI5 app to realize different caching strategies.
Stars: ✭ 16 (+0%)
Mutual labels:  sample, sample-code
cloud-sdk-ios-samples
SAP Cloud Platform SDK for iOS sample apps demonstrating various components and features of the SDK in the context of bigger apps.
Stars: ✭ 20 (+25%)
Mutual labels:  sample, sample-code
devtoberfest-2021
The home of Devtoberfest 2021 - an open celebration of what makes us developers - coding and collaboration!
Stars: ✭ 212 (+1225%)
Mutual labels:  sample, sample-code
cloud-cap-risk-management
The SAP Risk Management example applications show how to deploy a CAP (SAP Cloud Application Programming model) application to Cloud Foundry and Kyma.
Stars: ✭ 36 (+125%)
Mutual labels:  sample, sample-code
cloud-function-nodejs-samples
SAP Cloud Platform Functions samples written in Node.JS
Stars: ✭ 14 (-12.5%)
Mutual labels:  sample, sample-code

JAK

REUSE status


Attention: This is sample code!

This repository contains sample code which should not be used in production. It only shows the capabilities of APACK - the ABAP package and dependency manager.


The JSON ABAP Konverter

The JSON ABAP Konverter (JAK) is an alternative way of handling JSON on an ABAP system running on the SAP Cloud Platform. Keep in mind that this is just a demo. In production, you better use the officially supported libraries...

Just hand your JSON raw data as string or encapsulated in an HTTP request to the JAK library and it will automatically transfer the JSON data to a compatible ABAP structure or internal table - and vice versa. No need to develop anything on your own - JAK will do the magic for you. Data structure matching is done based on the names of the table/structure rows and the JSON identifiers. The ABAP data field can contain more or less fields than the JSON which is used, JAK will automatically only copy the matching fields and silently ignore the rest.

Prerequisites

Please make sure to fulfill the following requirements:

  • You have access to an SAP Cloud Platform ABAP Environment instance (see here for additional information)
  • You have downloaded and installed ABAP Development Tools for SAP NetWeaver (ADT)
  • You have created an ABAP Cloud Project in ADT that allows you to access your SAP Cloud Platform ABAP Environment instance
  • You have installed the abapGit plug-in for Eclipse via the updatesite
  • You have installed the YY Data Service or run an ABAP instance which supports the APACK package and dependency manager. This will import the YY Data Service automatically when you import this project.

Download and Installation

Use the abapGit plug-in to install the JSON ABAP Konverter by executing the following steps:

  • In ADT create the package /DMO/JAK as a subpackage under /DMO/SAP (keep the defaulted values)
  • In ADT click on Window > Show View > Other... and choose the entry abapGit Repositories to open the abapGit view
  • Make sure to have the correct ABAP Cloud Project selected (See the little headline in the abapGit view for the current project)
  • Click on the + icon to clone an abapGit repository
  • Provide the URL of this repository: https://github.com/SAP/abap-platform-jak.git
  • On the next page choose the master branch and provide the package /DMO/JAK
  • Provide a valid transport request and choose Finish. This starts the cloning of the repository - which might take a few minutes
  • Once the cloning has finished, refresh your project tree
  • Usually, the imported objects are not activated after cloning. Use the mass activation feature in ADT to activate those artifacts.

Usage

Incoming data

You already have a JSON with data or you get it via an HTTP reqest and would like to transfer it to a compatible ABAP data field? Nothing easier than that: Just get an instance of ZCL_JAK_DATA_IN by calling the corresponding static method - either INITIALIZE_WITH_HTTP_REQUEST or INITIALIZE_WITH_JSON. Your ABAP data field can then simply be filled by calling the method ZIF_JAK_DATA_IN~FILL.

Outgoing data

You have an ABAP data field ready to send out to the world as JSON - either directly the text or in an HTTP response? If you want to get it converted automatically, simply initialze ZCL_JAK_DATA_OUT by calling the INITIALIZE method and pass your field to it. The methods ZIF_JAK_DATA_OUT~GET_JSON and ZIF_JAK_DATA_OUT~PREPARE_HTTP_RESPONSE will do the job for you.

Known Issues

As mentioned before, after cloning a abapGit repository some objects might not be active. Use the mass activation feature in ADT to activate those artifacts.

License

Copyright (c) 2019-2020 SAP SE or an SAP affiliate company.

Licensed under the Apache License, Version 2.0 (the "License"); you may not use any file of this project except in compliance with the License.

You may obtain a copy of the License at https://www.apache.org/licenses/LICENSE-2.0.

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the LICENSE for the specific language governing permissions and limitations under the License.

Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].