IT. Expert System.

Android Reference

Uri.Builder


android.net

Class Uri.Builder

  • Enclosing class:
    Uri


    public static final class Uri.Builder
    extends Object
    Helper class for building or manipulating URI references. Not safe for concurrent use.

    An absolute hierarchical URI reference follows the pattern: <scheme>://<authority><absolute path>?<query>#<fragment>

    Relative URI references (which are always hierarchical) follow one of two patterns: <relative or absolute path>?<query>#<fragment> or //<authority><absolute path>?<query>#<fragment>

    An opaque URI follows this pattern: <scheme>:<opaque part>#<fragment>

    Use Uri.buildUpon() to obtain a builder representing an existing URI.

    • Constructor Detail

      • Uri.Builder

        public Uri.Builder()
        Constructs a new Builder.
    • Method Detail

      • scheme

        public Uri.Builder scheme(String scheme)
        Sets the scheme.
        Parameters:
        scheme - name or null if this is a relative Uri
      • opaquePart

        public Uri.Builder opaquePart(String opaquePart)
        Encodes and sets the given opaque scheme-specific-part.
        Parameters:
        opaquePart - decoded opaque part
      • encodedOpaquePart

        public Uri.Builder encodedOpaquePart(String opaquePart)
        Sets the previously encoded opaque scheme-specific-part.
        Parameters:
        opaquePart - encoded opaque part
      • authority

        public Uri.Builder authority(String authority)
        Encodes and sets the authority.
      • encodedAuthority

        public Uri.Builder encodedAuthority(String authority)
        Sets the previously encoded authority.
      • path

        public Uri.Builder path(String path)
        Sets the path. Leaves '/' characters intact but encodes others as necessary.

        If the path is not null and doesn't start with a '/', and if you specify a scheme and/or authority, the builder will prepend the given path with a '/'.

      • encodedPath

        public Uri.Builder encodedPath(String path)
        Sets the previously encoded path.

        If the path is not null and doesn't start with a '/', and if you specify a scheme and/or authority, the builder will prepend the given path with a '/'.

      • appendPath

        public Uri.Builder appendPath(String newSegment)
        Encodes the given segment and appends it to the path.
      • appendEncodedPath

        public Uri.Builder appendEncodedPath(String newSegment)
        Appends the given segment to the path.
      • encodedQuery

        public Uri.Builder encodedQuery(String query)
        Sets the previously encoded query.
      • fragment

        public Uri.Builder fragment(String fragment)
        Encodes and sets the fragment.
      • encodedFragment

        public Uri.Builder encodedFragment(String fragment)
        Sets the previously encoded fragment.
      • appendQueryParameter

        public Uri.Builder appendQueryParameter(String key,
                                       String value)
        Encodes the key and value and then appends the parameter to the query string.
        Parameters:
        key - which will be encoded
        value - which will be encoded
      • clearQuery

        public Uri.Builder clearQuery()
        Clears the the previously set query.
      • toString

        public String toString()
        Description copied from class: Object
        Returns a string containing a concise, human-readable description of this object. Subclasses are encouraged to override this method and provide an implementation that takes into account the object's type and data. The default implementation is equivalent to the following expression:
           getClass().getName() + '@' + Integer.toHexString(hashCode())

        See Writing a useful toString method if you intend implementing your own toString method.

        Overrides:
        toString in class Object
        Returns:
        a printable representation of this object.


Content

Android Reference

Java basics

Java Enterprise Edition (EE)

Java Standard Edition (SE)

SQL

HTML

PHP

CSS

Java Script

MYSQL

JQUERY

VBS

REGEX

C

C++

C#

Design patterns

RFC (standard status)

RFC (proposed standard status)

RFC (draft standard status)

RFC (informational status)

RFC (experimental status)

RFC (best current practice status)

RFC (historic status)

RFC (unknown status)

IT dictionary

License.
All information of this service is derived from the free sources and is provided solely in the form of quotations. This service provides information and interfaces solely for the familiarization (not ownership) and under the "as is" condition.
Copyright 2016 © ELTASK.COM. All rights reserved.
Site is optimized for mobile devices.
Downloads: 1565 / . Delta: 0.02386 с