• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License").
5  * You may not use this file except in compliance with the License.
6  * A copy of the License is located at
7  *
8  *  http://aws.amazon.com/apache2.0
9  *
10  * or in the "license" file accompanying this file. This file is distributed
11  * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12  * express or implied. See the License for the specific language governing
13  * permissions and limitations under the License.
14  */
15 
16 package software.amazon.awssdk.core.document;
17 
18 import java.util.List;
19 import java.util.Map;
20 import software.amazon.awssdk.annotations.SdkPublicApi;
21 import software.amazon.awssdk.core.SdkNumber;
22 
23 /**
24  * Document visitor interface with no return type.
25  *
26  */
27 @SdkPublicApi
28 public interface VoidDocumentVisitor {
29 
30     /**
31      * Visits a Document Null.
32      */
visitNull()33     default void visitNull() {
34     }
35 
36     /**
37      * Visits a Boolean Document.
38      * @param document Document to visit,
39      */
visitBoolean(Boolean document)40     default void visitBoolean(Boolean document) {
41     }
42 
43     /**
44      * Visits a String Document.
45      * @param document Document to visit,
46      */
visitString(String document)47     default void visitString(String document) {
48     }
49 
50     /**
51      * Visits a Number Document.
52      * @param document Document to visit,
53      */
visitNumber(SdkNumber document)54     default void visitNumber(SdkNumber document) {
55     }
56 
57     /**
58      * Visits a Map Document.
59      * @param documentMap Document to visit,
60      */
visitMap(Map<String, Document> documentMap)61     default void visitMap(Map<String, Document> documentMap) {
62     }
63 
64     /**
65      * Visits a List Document.
66      * @param documentList Document to visit,
67      */
visitList(List<Document> documentList)68     default void visitList(List<Document> documentList) {
69     }
70 
71 }
72