Home | History | Annotate | Download | only in src

Lines Matching defs:Component

44 // Component ------------------------------------------------------------------
47 struct Component {
48 Component() : begin(0), len(-1) {}
51 Component(int b, int l) : begin(b), len(l) {}
57 // Returns true if this component is valid, meaning the length is given. Even
63 // Returns true if the given component is specified on false, the component
74 bool operator==(const Component& other) const {
78 int begin; // Byte offset in the string of this component.
79 int len; // Will be -1 if the component is unspecified.
82 // Helper that returns a component created with the given begin and ending
84 inline Component MakeRange(int begin, int end) {
85 return Component(begin, end - begin);
97 // url_parse::Component scheme;
101 // if (IsStandardScheme(url, scheme)) // Not provided by this component
103 // else if (IsFileURL(url, scheme)) // Not provided by this component
124 // Returns the length of the URL (the end of the last component).
132 // Returns the number of characters before the given component if it exists,
133 // or where the component would be if it did exist. This will return the
134 // string length if the component would be appended to the end.
138 // component. The |include_delimiter| flag controls if you want this counted
139 // as part of the component or not when the component exists.
165 Component scheme;
168 Component username;
174 Component password;
177 Component host;
180 Component port;
187 Component path;
192 Component query;
198 Component ref;
259 bool ExtractScheme(const char* url, int url_len, Component* scheme);
260 bool ExtractScheme(const char16* url, int url_len, Component* scheme);
267 // component is not found, it will be set to invalid.
269 const Component& auth,
270 Component* username,
271 Component* password,
272 Component* hostname,
273 Component* port_num);
275 const Component& auth,
276 Component* username,
277 Component* password,
278 Component* hostname,
279 Component* port_num);
281 // Computes the integer port value from the given port component. The port
282 // component should have been identified by one of the init functions on
288 int ParsePort(const char* url, const Component& port);
289 int ParsePort(const char16* url, const Component& port);
302 const Component& path,
303 Component* file_name);
305 const Component& path,
306 Component* file_name);
318 // The initial query component should not include the '?' (this is the default
324 Component* query,
325 Component* key,
326 Component* value);
328 Component* query,
329 Component* key,
330 Component* value);