EMMA Coverage Report (generated Mon Oct 17 05:41:20 EDT 2011)
[all classes][org.jclouds.azureblob.options]

COVERAGE SUMMARY FOR SOURCE FILE [ListBlobsOptions.java]

nameclass, %method, %block, %line, %
ListBlobsOptions.java100% (2/2)23%  (3/13)25%  (19/76)29%  (5.5/19)

COVERAGE BREAKDOWN BY CLASS AND METHOD

nameclass, %method, %block, %line, %
     
class ListBlobsOptions$Builder100% (1/1)17%  (1/6)19%  (8/42)18%  (2/11)
ListBlobsOptions$Builder (): void 0%   (0/1)0%   (0/3)0%   (0/1)
includeMetadata (): ListBlobsOptions 0%   (0/1)0%   (0/7)0%   (0/2)
marker (String): ListBlobsOptions 0%   (0/1)0%   (0/8)0%   (0/2)
maxResults (int): ListBlobsOptions 0%   (0/1)0%   (0/8)0%   (0/2)
prefix (String): ListBlobsOptions 0%   (0/1)0%   (0/8)0%   (0/2)
delimiter (String): ListBlobsOptions 100% (1/1)100% (8/8)100% (2/2)
     
class ListBlobsOptions100% (1/1)29%  (2/7)32%  (11/34)44%  (4/9)
getDelimiter (): String 0%   (0/1)0%   (0/4)0%   (0/1)
includeMetadata (): ListBlobsOptions 0%   (0/1)0%   (0/4)0%   (0/1)
marker (String): ListBlobsOptions 0%   (0/1)0%   (0/5)0%   (0/1)
maxResults (int): ListBlobsOptions 0%   (0/1)0%   (0/5)0%   (0/1)
prefix (String): ListBlobsOptions 0%   (0/1)0%   (0/5)0%   (0/1)
ListBlobsOptions (): void 100% (1/1)100% (3/3)100% (2/2)
delimiter (String): ListBlobsOptions 100% (1/1)100% (8/8)100% (2/2)

1/**
2 * Licensed to jclouds, Inc. (jclouds) under one or more
3 * contributor license agreements.  See the NOTICE file
4 * distributed with this work for additional information
5 * regarding copyright ownership.  jclouds licenses this file
6 * to you under the Apache License, Version 2.0 (the
7 * "License"); you may not use this file except in compliance
8 * with the License.  You may obtain a copy of the License at
9 *
10 *   http://www.apache.org/licenses/LICENSE-2.0
11 *
12 * Unless required by applicable law or agreed to in writing,
13 * software distributed under the License is distributed on an
14 * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
15 * KIND, either express or implied.  See the License for the
16 * specific language governing permissions and limitations
17 * under the License.
18 */
19package org.jclouds.azureblob.options;
20 
21import org.jclouds.azure.storage.options.ListOptions;
22 
23/**
24 * Contains options supported in the REST API for the List Blobs operation. <h2>
25 * Usage</h2> The recommended way to instantiate a ListBlobsOptions object is to statically import
26 * ListBlobsOptions.* and invoke a static creation method followed by an instance mutator (if
27 * needed):
28 * <p/>
29 * <code>
30 * import static org.jclouds.azureblob.options.ListBlobsOptions.Builder.*
31 * import org.jclouds.azureblob.AzureBlobClient;
32 * <p/>
33 * AzureBlobClient connection = // get connection
34 * Set<BlobMetadata> blobs = connection.listBlobs("containerName", delimiter("/"));
35 * <code> *
36 * 
37 * @see <a href="http://msdn.microsoft.com/en-us/library/dd179466.aspx" />
38 * @author Adrian Cole
39 */
40public class ListBlobsOptions extends ListOptions {
41 
42   /**
43    * When the request includes this parameter, the operation returns a {@code BlobPrefix} element
44    * in the response body that acts as a placeholder for all blobs whose names begin with the same
45    * substring up to the appearance of the delimiter character.
46    * 
47    * @param delimiter
48    *           a single character or a string.
49    */
50   public ListBlobsOptions delimiter(String delimiter) {
51      this.queryParameters.put("delimiter", delimiter);
52      return this;
53   }
54 
55   public String getDelimiter() {
56      return this.getFirstQueryOrNull("delimiter");
57   }
58 
59   public static class Builder {
60 
61      /**
62       * @see ListBlobsOptions#delimiter(String)
63       */
64      public static ListBlobsOptions delimiter(String delimiter) {
65         ListBlobsOptions options = new ListBlobsOptions();
66         return options.delimiter(delimiter);
67      }
68 
69      /**
70       * @see ListOptions#includeMetadata()
71       */
72      public static ListBlobsOptions includeMetadata() {
73         ListBlobsOptions options = new ListBlobsOptions();
74         return options.includeMetadata();
75      }
76 
77      /**
78       * @see ListOptions#prefix(String)
79       */
80      public static ListBlobsOptions prefix(String prefix) {
81         ListBlobsOptions options = new ListBlobsOptions();
82         return options.prefix(prefix);
83      }
84 
85      /**
86       * @see ListOptions#marker(String)
87       */
88      public static ListBlobsOptions marker(String marker) {
89         ListBlobsOptions options = new ListBlobsOptions();
90         return options.marker(marker);
91      }
92 
93      /**
94       * @see ListOptions#maxResults(long)
95       */
96      public static ListBlobsOptions maxResults(int maxKeys) {
97         ListBlobsOptions options = new ListBlobsOptions();
98         return options.maxResults(maxKeys);
99      }
100   }
101 
102   /**
103    * {@inheritDoc}
104    */
105   @Override
106   public ListBlobsOptions includeMetadata() {
107      return (ListBlobsOptions) super.includeMetadata();
108   }
109 
110   /**
111    * {@inheritDoc}
112    */
113   @Override
114   public ListBlobsOptions marker(String marker) {
115      return (ListBlobsOptions) super.marker(marker);
116   }
117 
118   /**
119    * {@inheritDoc}
120    */
121   @Override
122   public ListBlobsOptions maxResults(int maxresults) {
123      return (ListBlobsOptions) super.maxResults(maxresults);
124   }
125 
126   /**
127    * {@inheritDoc}
128    */
129   @Override
130   public ListBlobsOptions prefix(String prefix) {
131      return (ListBlobsOptions) super.prefix(prefix);
132   }
133}

[all classes][org.jclouds.azureblob.options]
EMMA 2.0.5312 (C) Vladimir Roubtsov