예제 #1
0
HTTPHeaderDomain GetHeaderDomain( std::string& domain){
    static std::unordered_map<std::string,HTTPHeaderDomain> domainTable={
            {"HOST",HeaderDomainType::HOST},
            {"ACCEPT",HeaderDomainType::ACCEPT},
            {"ACCEPT-CHARSET",HeaderDomainType::ACCEPT_CHARSET},
            {"ACCEPT-ENCODING",HeaderDomainType::ACCEPT_ENCODING},
            {"ACCEPT-LANGUAGE",HeaderDomainType::ACCEPT_LANGUAGE},
            {"ACCEPT-DATETIME",HeaderDomainType::ACCEPT_DATETIME},
            {"CONNECTION",HeaderDomainType::CONNECTION},
            {"COOKIE",HeaderDomainType::COOKIE},
            {"CONTENT-LENGTH",HeaderDomainType::CONTENT_LENGTH},
            {"CONTENT-TYPE",HeaderDomainType::CONTENT_TYPE},
            {"REFERER",HeaderDomainType::REFERER},
            {"USER-AGENT",HeaderDomainType::USER_AGENT}
    };
    return _GetType(domainTable,domain);
}
예제 #2
0
Protocol GetProtocol( std::string& protocol){
    static std::unordered_map<std::string,Protocol> protocolTable={{"HTTP1_0",ProtocolType::HTTP1_0},{"HTTP1_1",ProtocolType::HTTP1_1}};
    std::string proto(protocol);
    std::replace(proto.begin(),proto.end(),'.','_');
    return _GetType(protocolTable,proto);
}
예제 #3
0
HTTPMethod GetHTTPMethod( std::string& method){
    static std::unordered_map<std::string,HTTPMethod> methodTable={{"POST",HTTPMethodType::POST},{"GET",HTTPMethodType::GET},{"DELETE",HTTPMethodType::DELETE},{"UPDATE",HTTPMethodType::UPDATE}};
    return _GetType(methodTable,method);
}
예제 #4
0
URLScheme GetURLScheme(std::string& scheme){
    static std::unordered_map<std::string,URLScheme> schemeTable={{"HTTP",URLSchemeType::HTTP},{"HTTPS",URLSchemeType::HTTPS},{"FTP",URLSchemeType::FTP},{"MAILTO",URLSchemeType::MAILTO}};
    return _GetType(schemeTable,scheme);
}
예제 #5
0
파일: schemaBase.cpp 프로젝트: MWDD/USD
SdfPrimSpecHandle
UsdSchemaBase::GetSchemaClassPrimDefinition() const
{
    return UsdSchemaRegistry::GetPrimDefinition(_GetType());
}