Loading ttcn/Http/LibItsHttp_BinaryMessageBodyTypes.ttcn 0 → 100644 +26 −0 Original line number Diff line number Diff line /** * @author ETSI / STF545 * @version $URL$ * $ID:$ * @desc This module provides the custom binary types for ITS HTTP based protocols. * @copyright ETSI Copyright Notification * No part may be reproduced except as authorized by written permission. * The copyright and the foregoing restriction extend to reproduction in all media. * All rights reserved. */ module LibItsHttp_BinaryMessageBodyTypes { /** * This file volontary contains a trivial declaration of the type BinaryBodu. * In accordance with your TTCN-3 module LibItsHttp_XMLTypes, you have to change the BinaryBody typing. */ // TODO Add here your custom binary import type union BinaryBody { // TODO Add here your custom variants octetstring raw } with { variant "" } } // End of LibItsHttp_BinaryMessageBodyTypes ttcn/Http/LibItsHttp_BinaryTemplates.ttcn 0 → 100644 +32 −0 Original line number Diff line number Diff line /** * @author ETSI / STF545 * @version $URL$ * $ID:$ * @desc This module provides the custom templates for ITS HTTP based protocols. * @copyright ETSI Copyright Notification * No part may be reproduced except as authorized by written permission. * The copyright and the foregoing restriction extend to reproduction in all media. * All rights reserved. */ module LibItsHttp_BinaryTemplates { // LibItsHttp import from LibItsHttp_BinaryMessageBodyTypes all; // TODO Add here your custom binary import template (value) BinaryBody m_binary_body_raw( in template (value) octetstring p_raw ) := { raw := p_raw } // End of template m_binary_body_raw template (present) BinaryBody mw_binary_body_raw( template (present) octetstring p_raw := ? ) := { raw := p_raw } // End of template mw_binary_body_raw // TODO Add here your custom binary template } // End of module LibItsHttp_BinaryTemplates ttcn/Http/LibItsHttp_BinaryTypes.ttcn 0 → 100644 +9 −0 Original line number Diff line number Diff line module LibItsHttp_BinaryTypes { // FIXME To be removed /** * This file is volontary empry. You have to declare all XSD files required by your project * In addition, the TTCN-3 module LibItsHttp_XmlMessageBodyTypes have to be updated too. */ // TODO Add here your custom binary import } // End of module LibItsHttp_BinaryTypes ttcn/Http/LibItsHttp_MessageBodyTypes.ttcn +2 −3 Original line number Diff line number Diff line Loading @@ -2,15 +2,14 @@ module LibItsHttp_MessageBodyTypes { // LibHttp import from LibItsHttp_XmlMessageBodyTypes all; type octetstring MsdBody; import from LibItsHttp_BinaryMessageBodyTypes all; type charstring HtmlBody; type charstring TextBody; type union HttpMessageBody { MsdBody ms_body, BinaryBody binary_body, HtmlBody html_body, XmlBody xml_body, TextBody text_body Loading ttcn/Http/LibItsHttp_Templates.ttcn +30 −0 Original line number Diff line number Diff line Loading @@ -15,6 +15,7 @@ module LibItsHttp_Templates { import from LibItsHttp_TypesAndValues all; import from LibItsHttp_MessageBodyTypes all; import from LibItsHttp_XmlMessageBodyTypes all; import from LibItsHttp_BinaryMessageBodyTypes all; group http_messages { Loading Loading @@ -71,6 +72,19 @@ module LibItsHttp_Templates { body := p_body } // End of template m_http_request_get template (omit) Request m_http_request_post( in charstring p_uri, in template (value) HeaderLines p_headers, in template (omit) HttpMessageBody p_body := omit ) := { method := "POST", uri := p_uri, version_major := c_http_version_major, version_minor := c_http_version_minor, header := p_headers, body := p_body } // End of template m_http_request_post } // End of group http_requests group http_responses { Loading Loading @@ -105,4 +119,20 @@ module LibItsHttp_Templates { } // End of group http_xml_body group http_binary_body { template (value) HttpMessageBody m_http_message_body_binary( in template (value) BinaryBody p_binary_body ) := { binary_body := p_binary_body } // End of template m_http_message_body_binary template (present) HttpMessageBody mw_http_message_body_binary( template (present) BinaryBody p_binary_body := ? ) := { binary_body := p_binary_body } // End of template mw_http_message_body_binary } // End of group http_binary_body } // End of module LibItsHttp_Templates Loading
ttcn/Http/LibItsHttp_BinaryMessageBodyTypes.ttcn 0 → 100644 +26 −0 Original line number Diff line number Diff line /** * @author ETSI / STF545 * @version $URL$ * $ID:$ * @desc This module provides the custom binary types for ITS HTTP based protocols. * @copyright ETSI Copyright Notification * No part may be reproduced except as authorized by written permission. * The copyright and the foregoing restriction extend to reproduction in all media. * All rights reserved. */ module LibItsHttp_BinaryMessageBodyTypes { /** * This file volontary contains a trivial declaration of the type BinaryBodu. * In accordance with your TTCN-3 module LibItsHttp_XMLTypes, you have to change the BinaryBody typing. */ // TODO Add here your custom binary import type union BinaryBody { // TODO Add here your custom variants octetstring raw } with { variant "" } } // End of LibItsHttp_BinaryMessageBodyTypes
ttcn/Http/LibItsHttp_BinaryTemplates.ttcn 0 → 100644 +32 −0 Original line number Diff line number Diff line /** * @author ETSI / STF545 * @version $URL$ * $ID:$ * @desc This module provides the custom templates for ITS HTTP based protocols. * @copyright ETSI Copyright Notification * No part may be reproduced except as authorized by written permission. * The copyright and the foregoing restriction extend to reproduction in all media. * All rights reserved. */ module LibItsHttp_BinaryTemplates { // LibItsHttp import from LibItsHttp_BinaryMessageBodyTypes all; // TODO Add here your custom binary import template (value) BinaryBody m_binary_body_raw( in template (value) octetstring p_raw ) := { raw := p_raw } // End of template m_binary_body_raw template (present) BinaryBody mw_binary_body_raw( template (present) octetstring p_raw := ? ) := { raw := p_raw } // End of template mw_binary_body_raw // TODO Add here your custom binary template } // End of module LibItsHttp_BinaryTemplates
ttcn/Http/LibItsHttp_BinaryTypes.ttcn 0 → 100644 +9 −0 Original line number Diff line number Diff line module LibItsHttp_BinaryTypes { // FIXME To be removed /** * This file is volontary empry. You have to declare all XSD files required by your project * In addition, the TTCN-3 module LibItsHttp_XmlMessageBodyTypes have to be updated too. */ // TODO Add here your custom binary import } // End of module LibItsHttp_BinaryTypes
ttcn/Http/LibItsHttp_MessageBodyTypes.ttcn +2 −3 Original line number Diff line number Diff line Loading @@ -2,15 +2,14 @@ module LibItsHttp_MessageBodyTypes { // LibHttp import from LibItsHttp_XmlMessageBodyTypes all; type octetstring MsdBody; import from LibItsHttp_BinaryMessageBodyTypes all; type charstring HtmlBody; type charstring TextBody; type union HttpMessageBody { MsdBody ms_body, BinaryBody binary_body, HtmlBody html_body, XmlBody xml_body, TextBody text_body Loading
ttcn/Http/LibItsHttp_Templates.ttcn +30 −0 Original line number Diff line number Diff line Loading @@ -15,6 +15,7 @@ module LibItsHttp_Templates { import from LibItsHttp_TypesAndValues all; import from LibItsHttp_MessageBodyTypes all; import from LibItsHttp_XmlMessageBodyTypes all; import from LibItsHttp_BinaryMessageBodyTypes all; group http_messages { Loading Loading @@ -71,6 +72,19 @@ module LibItsHttp_Templates { body := p_body } // End of template m_http_request_get template (omit) Request m_http_request_post( in charstring p_uri, in template (value) HeaderLines p_headers, in template (omit) HttpMessageBody p_body := omit ) := { method := "POST", uri := p_uri, version_major := c_http_version_major, version_minor := c_http_version_minor, header := p_headers, body := p_body } // End of template m_http_request_post } // End of group http_requests group http_responses { Loading Loading @@ -105,4 +119,20 @@ module LibItsHttp_Templates { } // End of group http_xml_body group http_binary_body { template (value) HttpMessageBody m_http_message_body_binary( in template (value) BinaryBody p_binary_body ) := { binary_body := p_binary_body } // End of template m_http_message_body_binary template (present) HttpMessageBody mw_http_message_body_binary( template (present) BinaryBody p_binary_body := ? ) := { binary_body := p_binary_body } // End of template mw_http_message_body_binary } // End of group http_binary_body } // End of module LibItsHttp_Templates