Lines Matching defs:Part
130 public static final Uri EMPTY = new HierarchicalUri(null, Part.NULL,
131 PathPart.EMPTY, Part.NULL, Part.NULL);
140 * Absolute URIs are hierarchical if the scheme-specific part starts with
147 * scheme-specific part of an opaque URI cannot start with a '/'.
179 * Gets the scheme-specific part of this URI, i.e. everything between
185 * @return the decoded scheme-specific-part
190 * Gets the scheme-specific part of this URI, i.e. everything between
197 * @return the decoded scheme-specific-part
202 * Gets the decoded authority part of this URI. For
213 * Gets the encoded authority part of this URI. For
295 * Gets the decoded fragment part of this URI, everything after the '#'.
302 * Gets the encoded fragment part of this URI, everything after the '#'.
457 "file", Part.EMPTY, path, Part.NULL, Part.NULL);
549 private Part ssp;
551 private Part getSsp() {
552 return ssp == null ? ssp = Part.fromEncoded(parseSsp()) : ssp;
573 private Part authority;
575 private Part getAuthorityPart() {
579 return authority = Part.fromEncoded(encodedAuthority);
638 private Part query;
640 private Part getQueryPart() {
642 ? query = Part.fromEncoded(parseQuery()) : query;
675 private Part fragment;
677 private Part getFragmentPart() {
679 ? fragment = Part.fromEncoded(parseFragment()) : fragment;
805 * @param ssp scheme-specific-part, everything between the
825 return new OpaqueUri(scheme, Part.fromDecoded(ssp),
826 Part.fromDecoded(fragment));
838 private final Part ssp;
839 private final Part fragment;
841 private OpaqueUri(String scheme, Part ssp, Part fragment) {
844 this.fragment = fragment == null ? Part.NULL : fragment;
850 Part.readFrom(parcel),
851 Part.readFrom(parcel)
1051 private Part userInfo;
1053 private Part getUserInfoPart() {
1055 ? userInfo = Part.fromEncoded(parseUserInfo()) : userInfo;
1144 private final Part authority;
1146 private final Part query;
1147 private final Part fragment;
1149 private HierarchicalUri(String scheme, Part authority, PathPart path,
1150 Part query, Part fragment) {
1152 this.authority = Part.nonNull(authority);
1154 this.query = Part.nonNull(query);
1155 this.fragment = Part.nonNull(fragment);
1161 Part.readFrom(parcel),
1163 Part.readFrom(parcel),
1164 Part.readFrom(parcel)
1193 private Part ssp;
1195 private Part getSsp() {
1197 ? ssp = Part.fromEncoded(makeSchemeSpecificPart()) : ssp;
1209 * Creates the encoded scheme-specific part from its sub parts.
1318 * {@code <scheme>:<opaque part>#<fragment>}
1325 private Part opaquePart;
1326 private Part authority;
1328 private Part query;
1329 private Part fragment;
1346 Builder opaquePart(Part opaquePart) {
1352 * Encodes and sets the given opaque scheme-specific-part.
1354 * @param opaquePart decoded opaque part
1357 return opaquePart(Part.fromDecoded(opaquePart));
1361 * Sets the previously encoded opaque scheme-specific-part.
1363 * @param opaquePart encoded opaque part
1366 return opaquePart(Part.fromEncoded(opaquePart));
1369 Builder authority(Part authority) {
1381 return authority(Part.fromDecoded(authority));
1388 return authority(Part.fromEncoded(authority));
1436 Builder query(Part query) {
1448 return query(Part.fromDecoded(query));
1455 return query(Part.fromEncoded(query));
1458 Builder fragment(Part fragment) {
1467 return fragment(Part.fromDecoded(fragment));
1474 return fragment(Part.fromEncoded(fragment));
1492 query = Part.fromEncoded(encodedParameter);
1498 query = Part.fromEncoded(encodedParameter);
1500 query = Part.fromEncoded(oldQuery + "&" + encodedParameter);
1510 return query((Part) null);
1547 || (authority != null && authority != Part.NULL);
1942 * Support for part implementations.
1947 * Enum which indicates which representation of a given part we have.
1995 * Immutable wrapper of encoded and decoded versions of a URI part. Lazily
1998 static class Part extends AbstractPart {
2000 /** A part with null values. */
2001 static final Part NULL = new EmptyPart(null);
2003 /** A part with empty strings for values. */
2004 static final Part EMPTY = new EmptyPart("");
2006 private Part(String encoded, String decoded) {
2020 static Part readFrom(Parcel parcel) {
2036 * Returns given part or {@link #NULL} if the given part is null.
2038 static Part nonNull(Part part) {
2039 return part == null ? NULL : part;
2043 * Creates a part from the encoded string.
2045 * @param encoded part string
2047 static Part fromEncoded(String encoded) {
2052 * Creates a part from the decoded string.
2054 * @param decoded part string
2056 static Part fromDecoded(String decoded) {
2061 * Creates a part from the encoded and decoded strings.
2063 * @param encoded part string
2064 * @param decoded part string
2066 static Part
2084 return new Part(encoded, decoded);
2087 private static class EmptyPart extends Part {
2100 * Immutable wrapper of encoded and decoded versions of a path part. Lazily
2105 /** A part with null values. */
2108 /** A part with empty strings for values. */
2222 * @param encoded part string
2231 * @param decoded part string
2240 * @param encoded part string
2241 * @param decoded part string