• Skip to main content
  • Skip to header right navigation
  • Skip to site footer
CDP Studio logo

CDP Studio

The no-code and full-code software development tool for distributed control systems and HMI

  • Why CDP
    • Software developers
    • Automation engineers
    • Managers
  • Product
    • Design UI
    • Develop
    • Analyze and test
    • Deploy
    • Framework and toolbox
    • Compatibility
  • Services
  • Use cases
  • Pricing
  • Try CDP

CDP Studio Documentation

  • Framework - CDP Core
  • Url
  • 4.11.14

Url Class

The Url extends ipaddress to store extra information like port, protocol etc. More...

Header: #include <OSAPI/Network/IpAddress.h>
Inherits: IpAddress
  • List of all members, including inherited members

Public Functions

Url()
Url(const char *url)
const char *Path() const
int Port() const
const char *Protocol() const
Url &operator=(const char *url)
  • 31 public functions inherited from IpAddress

Detailed Description

The Url extends ipaddress to store extra information like port, protocol etc.

Has methods to decode typical urls like 'http://www.icd.no', 'www.icd.no:80' etc.

Usage, f.ex to get Google's ip-address: Url google = "http://www.google.com";

If a protocol is specified, but no port, the default port for that protocol is used (e.g port 80 for http).

Throws exception if:

  • the hostname cannot be determined
  • the hostname cannot be looked up
  • neither a known protocol nor port is specified

See also IpAddress.

Member Function Documentation

Url::Url()

Constructs an Url.

Url::Url(const char *url)

Constructs an Url with input url.

const char *Url::Path() const

Returns the path of the url.

int Url::Port() const

Returns the port number of the url.

const char *Url::Protocol() const

Returns the protocol of the url.

Url &Url::operator=(const char *url)

Assigns and constructs the class based on url given.

The content of this document is confidential information not to be published without the consent of CDP Technologies AS.

CDP Technologies AS, www.cdpstudio.com

Get started with CDP Studio today

Let us help you take your great ideas and turn them into the products your customer will love.

Try CDP Studio for free
Why CDP Studio?

CDP Technologies AS
Hundsværgata 8,
P.O. Box 144
6001 Ålesund, Norway

Tel: +47 990 80 900
E-mail: info@cdptech.com

Company

About CDP

Contact us

Services

Partners

Blog

Developers

Get started

User manuals

Support

Document download

Release notes

Follow CDP

  • LinkedIn
  • YouTube
  • GitHub

    © Copyright 2022 CDP Technologies. Privacy and cookie policy.

    Return to top