Top Banner
www.uniface.com lectu res. lectu res.
15

Uniface Lectures Webinar - Integration

Jan 24, 2017

Download

Software

Uniface
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript
Page 1: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

l ectures.

Page 2: Uniface Lectures Webinar - Integration

Uniface 9.7 Web integrationAndy HolzmanSoftware DeveloperJune 16th, 2016

l ectures.

Page 3: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

Web IntegrationREST API’sOneDrive

New UHTTP Functionality

Page 4: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

AgendaPre-requisite:You must have a OneDrive account.(Not OneDrive for Business)

What we will coverIntroduction to REST

Uniface Web Capabilities

Using REST-ful Services

Page 5: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

RESTRepresentational State Transfer

Roy Fielding used the term in his doctorate

Design principles for HTTP

REST-ful ServicesUse standard HTTP methods Move away from the complexity of SOAP

Page 6: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

Uniface CapabilitiesUniface HTTP Clients

HTML WidgetFor interactive use

UHTTP ComponentUsed in PROC

Uniface HTTP ServersUSP, Static Server PageDSP, Dynamic Server Page

Page 7: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

What is an HTTP Request?A network message sent to a URL, consisting in its simplest form, of:-Header lineHeader line…

Body lineBody line….

Page 8: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

UHTTP ComponentUHTTP Component uses this simple form of HTTP request. There is no support for Multi-Part requests.

Some API’s offer the capability to get meta-data and a file.

The UHTTP Component must use two separate requests.

Page 9: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

UHTTP Component

Send a request and receive a response.

Send(URL, Method, user, pass, Headers, Contents, Status Line)

Send a file and receive a response.

Load_File_Contents(Filename, OptionList)

Send(URL, Method, user, pass, Headers, Contents, Status Line)

Page 10: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

UHTTP Component

Send(URL, Method, user, pass, Headers, Contents, Status Line)

Send a request and receive a response. The Contents field is a ‘string’ INOUT parameter. The developer provides the Contents which is sent as the body of the HTTP request. The response body is placed back into Contents.

Page 11: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

UHTTP Component

Load_File_Contents(Filename, OptionList)

Send(URL, Method, user, pass, Headers, Contents, Status Line)

Send a file and receive a response. The contents of the file will be loaded into the HTTP request body and sent. The Contents field is not used for input. The response body will be returned in the Contents field.

Page 12: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

UHTTP ComponentDump_File_Contents(Filename, OptionList)

Send(URL, Method, user, pass, Headers, Contents, Status Line)

Dump_File_Contents(Filename, OptionList)

Declare the HTTP response body to be a file. The Contents field is not used. Send the request for the file to the API. Dump the HTTP response body into a file.

Page 13: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

UHTTP ComponentGet_Info(Option, String_Information)

Get information about a file transfer. The file is transferred directly to and from the file system. The developer does not have access to it during the transfer. The transfer of the file may require information like a file size, a digest or a range header. This operation aids in creating for such items.

Page 14: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

Thank You!

Q & A

Page 15: Uniface Lectures Webinar - Integration

www.uniface.coml ectures.

Follow us online

uniface.comunifaceinfo.com/forum