2
|
1 |
// Copyright (c) 2009 The Chromium Authors. All rights reserved.
|
|
2 |
// Use of this source code is governed by a BSD-style license that can be
|
|
3 |
// found in the LICENSE file.
|
|
4 |
|
|
5 |
package org.chromium.sdk.internal.protocolparser;
|
|
6 |
|
|
7 |
/**
|
|
8 |
* A condition for property value. Implementation may provide any logic here.
|
|
9 |
* @param <T> type of value
|
|
10 |
* @see JsonSubtypeConditionCustom
|
|
11 |
*/
|
|
12 |
public interface JsonValueCondition<T> {
|
|
13 |
/**
|
|
14 |
* @param value parsed data from JSON property
|
|
15 |
* @return true if value satisfies condition
|
|
16 |
*/
|
|
17 |
boolean conforms(T value);
|
|
18 |
}
|