Skip to content
This repository has been archived by the owner on Aug 1, 2022. It is now read-only.

class net.http.Destination

BorisNen edited this page Jun 21, 2021 · 3 revisions

$.net.http.Destination Class

HTTP(s) destination that holds metadata, for example: host, port, useSSL. The destination can be retrieved from the database with $.net.http.readDestination.

Reference

  • SAP Help

https://help.sap.com/doc/3de842783af24336b6305a3c0223a369/2.0.03/en-US/$.net.http.Destination.html

  • Module

https://github.com/SAP/xsk/tree/main/modules/api/api-xsjs/src/main/resources/xsk/http

  • Sample usage:
let http = $.net.http;
let response_prev = require('http/v4/response');

/*
Read service.xshttpdest inside the Demo package that contains:
host=https://services.odata.org;
pathPrefix=/V4/Northwind/Northwind.svc/;
*/
let dest = http.readDestination("Demo", "service");
// Check if the file has been read properly
response_prev.println("Host: " +dest.host+ " Path Prefix: " +dest.pathPrefix);
  • Issues

https://github.com/SAP/xsk/issues/20

  • Unit Tests

https://github.com/SAP/xsk/tree/main/modules/engines/engine-xsjs/src/test/resources/test/xsk/http/http.xsjs

  • Integration Tests ❌

Wiki icons legend

✅ - Feature implemented and working as supposed.
⚠️ - Feature partially implemented and needs to be finished.
❌ - Feature not implemented yet.