Struct gip::ProviderInfo [] [src]

pub struct ProviderInfo {
    pub name: String,
    pub ptype: ProviderType,
    pub format: ProviderFormat,
    pub url: String,
    pub key: Vec<String>,
}

Fields

Provider name

Provider type

Provider format

URL for GET

Key for JSON format

Methods

impl ProviderInfo
[src]

Provider information.

Examples

use gip::{ProviderFormat, ProviderInfo, ProviderType};
let p = ProviderInfo::new()
    .name("inet-ip.info")
    .ptype(ProviderType::IPv4)
    .format(ProviderFormat::Plane)
    .url("http://inet-ip.info/ip")
    .key(&vec![]);
println!("{:?}", p);

[src]

[src]

[src]

[src]

[src]

[src]

[src]

Create Provider from this info

Trait Implementations

impl Debug for ProviderInfo
[src]

[src]

Formats the value using the given formatter. Read more

Auto Trait Implementations

impl Send for ProviderInfo

impl Sync for ProviderInfo