Home
last modified time | relevance | path

Searched refs:T (Results 1 – 25 of 82) sorted by relevance

1234

/cts/tests/tests/hardware/src/android/hardware/camera2/cts/helpers/
DCameraErrorCollector.java87 public <T> void checkThat(final T value, final Matcher<T> matcher) { in checkThat()
98 public <T> void checkThat(final String reason, final T value, final Matcher<T> matcher) { in checkThat()
143 public <T> boolean expectEquals(String msg, T expected, T actual) { in expectEquals()
165 public <T> boolean expectNotEquals(String msg, T expected, T actual) { in expectNotEquals()
185 public <T> boolean expectEquals(String msg, T[] expected, T[] actual) { in expectEquals()
210 public <T> boolean expectNotEquals(String msg, T[] expected, T[] actual) { in expectNotEquals()
232 public <T extends Comparable<? super T>> boolean expectGreater(String msg, T expected, in expectGreater()
233 T actual) { in expectGreater()
246 public <T extends Comparable<? super T>> boolean expectGreaterOrEqual(String msg, T expected, in expectGreaterOrEqual()
247 T actual) { in expectGreaterOrEqual()
[all …]
DInMatcher.java30 public class InMatcher<T> extends BaseMatcher<T> {
32 protected Collection<T> mValues;
34 public InMatcher(Collection<T> values) { in InMatcher()
39 public InMatcher(T... values) { in InMatcher()
47 T obj = (T) o; in matches()
48 for (T elem : mValues) { in matches()
62 public static <T> Matcher<T> in(T... operand) { in in()
63 return new InMatcher<T>(operand); in in()
67 public static <T> Matcher<T> in(Collection<T> operand) { in in()
68 return new InMatcher<T>(operand); in in()
DPreconditions.java60 public static <T> T checkEquals(String argName, T arg, in checkEquals()
61 String expectedName, T expectedValue) { in checkEquals()
85 public static <T> T checkNotNull(String argName, T arg) { in checkNotNull()
105 public static <T> T checkNotNull(T arg) { in checkNotNull()
138 public static <T> Collection<T> checkCollectionElementsNotNull(final Collection<T> value, in checkCollectionElementsNotNull()
145 for (T elem : value) { in checkCollectionElementsNotNull()
167 public static <T> Collection<T> checkCollectionNotEmpty(final Collection<T> value, in checkCollectionNotEmpty()
DAssertHelpers.java131 public static <T> void assertArrayContains(String message, T[] actual, T checkVals) { in assertArrayContains()
155 public static <T> T assertArrayContainsAnyOf(String message, T[] actual, T[] checkVals) { in assertArrayContainsAnyOf()
179 public static <T> T assertCollectionContainsAnyOf(String message, Collection<T> actual, in assertCollectionContainsAnyOf()
180 Collection<T> checkVals) { in assertCollectionContainsAnyOf()
182 T selected = null; in assertCollectionContainsAnyOf()
183 for (T check : checkVals) { in assertCollectionContainsAnyOf()
199 private static <T> List<T> buildList(T[] array) { in buildList()
200 return new ArrayList<T>(Arrays.asList(array)); in buildList()
211 private static <T> String formatCollection(Collection<T> collection, int maxLen) { in formatCollection()
216 for (T elem : collection) { in formatCollection()
DMaybeNull.java42 public static <T extends AutoCloseable> void close(T closeable) throws Exception { in close()
56 public static <T extends UncheckedCloseable> void close(T closeable) { in close()
68 public static <T extends Closeable> void close(T closeable) throws IOException { in close()
/cts/tools/signature-tools/src/signature/compare/model/impl/
DSigDelta.java29 public abstract class SigDelta<T> implements IDelta<T> {
30 private T from;
31 private T to;
33 public SigDelta(T from, T to) { in SigDelta()
38 public final T getFrom() { in getFrom()
42 public final T getTo() { in getTo()
56 private static <T extends IDelta<?>> Set<T> getDeltas(Set<T> deltas, in getDeltas()
58 Set<T> addedElements = new HashSet<T>(); in getDeltas()
59 for (T delta : deltas) { in getDeltas()
67 public static <T extends IDelta<?>> Set<T> getAdded(Set<T> deltas) { in getAdded()
[all …]
DSigTypeDefinitionDelta.java22 public abstract class SigTypeDefinitionDelta<T extends ITypeDefinition> extends
23 SigDelta<T> implements ITypeDefinitionDelta<T> {
25 public SigTypeDefinitionDelta(T from, T to) { in SigTypeDefinitionDelta()
DSigTypeDelta.java22 public class SigTypeDelta<T extends ITypeReference> extends SigDelta<T>
23 implements ITypeReferenceDelta<T> {
25 public SigTypeDelta(T from, T to) { in SigTypeDelta()
DSigMemberDelta.java27 public abstract class SigMemberDelta<T extends IField> extends SigDelta<T>
28 implements IMemberDelta<T> {
35 public SigMemberDelta(T from, T to) { in SigMemberDelta()
DSigExecutableMemberDelta.java29 public abstract class SigExecutableMemberDelta<T extends IExecutableMember>
30 extends SigDelta<T> implements IExecutableMemberDelta<T> {
38 public SigExecutableMemberDelta(T from, T to) { in SigExecutableMemberDelta()
/cts/apps/CtsVerifier/include/colorchecker/
Dvec2.h23 template <class T>
26 Vec2(T inputX, T inputY) { in Vec2()
33 inline Vec2<T> operator+ (const Vec2<T> &param) const {
34 Vec2<T> temp(mX + param.x(), mY + param.y());
38 inline Vec2<T> operator- (const Vec2<T> &param) const {
39 Vec2<T> temp(mX - param.x(), mY - param.y());
59 inline T x() const { return mX; } in x()
60 inline T y() const { return mY; } in y()
62 inline void set(const T inputX, const T inputY) { in set()
68 T mX;
[all …]
Dvec3.h24 template <class T>
27 Vec3(T inputRed, T inputGreen, T inputBlue) { in Vec3()
36 inline Vec3<T> operator+ (const Vec3<U> &param) const {
37 Vec3<T> temp(mRed + param.r(), mGreen + param.g(), mBlue + param.b());
41 inline Vec3<T> operator- (const Vec3<T> &param) const {
42 Vec3<T> temp(mRed - param.r(), mGreen - param.g(), mBlue - param.b());
46 inline Vec3<T> operator* (const int param) const {
47 Vec3<T> temp(mRed * param, mGreen * param, mBlue * param);
98 inline T r() const { return mRed; } in r()
99 inline T g() const { return mGreen; } in g()
[all …]
/cts/tests/tests/rscpp/librscpptest/
Dvector.rs3 #define MAKE_TEST(T) \
4 void vector_test_##T(T t) {} \
5 void vector_test_##T##2(T##2 t) {} \
6 void vector_test_##T##3(T##3 t) {} \
7 void vector_test_##T##4(T##4 t) {} \
/cts/tests/tests/util/src/android/util/cts/
DRangeTest.java132 private static <T extends Comparable<? super T>> void assertInRange(Range<T> object, T needle) { in assertInRange()
136 private static <T extends Comparable<? super T>> void assertOutOfRange(Range<T> object, in assertOutOfRange()
137 T needle) { in assertOutOfRange()
141 private static <T extends Comparable<? super T>> void assertUpper(Range<T> object, T expected) { in assertUpper()
145 private static <T extends Comparable<? super T>> void assertLower(Range<T> object, T expected) { in assertLower()
149 private static <T, T2> void assertAction(String action, T object, T2 expected, in assertAction()
155 private static <T, T2> void assertAction(String action, T object, T2 needle, boolean expected, in assertAction()
162 private static <T extends Comparable<? super T>> void assertHashCodeEquals( in assertHashCodeEquals()
163 Range<T> left, Range<T> right) { in assertHashCodeEquals()
DRationalTest.java413 private static <T> void assertAction(String action, T object, boolean expected, in assertAction()
420 private static <T extends Comparable<? super T>> void assertLessThan(T left, T right) { in assertLessThan()
427 private static <T extends Comparable<? super T>> void assertGreaterThan(T left, T right) { in assertGreaterThan()
434 private static <T extends Comparable<? super T>> void assertCompareEquals(T left, T right) { in assertCompareEquals()
441 private static <T extends Serializable> byte[] serialize(T obj) throws IOException { in serialize()
449 private static <T extends Serializable> T deserialize(byte[] array, Class<T> klass) in deserialize()
458 private static <T extends Serializable> T serializeRoundTrip(T obj) in serializeRoundTrip()
460 Class<T> klass = (Class<T>) obj.getClass(); in serializeRoundTrip()
462 T serialized = deserialize(arr, klass); in serializeRoundTrip()
466 private static <T extends Serializable> void assertEqualsAfterSerializing(T obj) in assertEqualsAfterSerializing()
[all …]
/cts/suite/audio_quality/lib/src/
DRWBuffer.h75 template <typename T> void write(T v) { in write()
77 assertWriteCapacity(sizeof(T)); in write()
78 memcpy(mBuffer + mWrPoint, src, sizeof(T)); in write()
79 mWrPoint += sizeof(T); in write()
87 template <typename T> T read() { in read()
88 T v; in read()
89 ASSERT((mRdPoint + sizeof(T)) <= mWrPoint); in read()
90 memcpy(&v, mBuffer + mRdPoint, sizeof(T)); in read()
91 mRdPoint += sizeof(T); in read()
/cts/tests/tests/renderscript/src/android/renderscript/cts/
DBaseObjTest.java30 Type T = TB.setX(1).create(); in testBaseObj() local
31 assertTrue(T != null); in testBaseObj()
32 BaseObj B = T; in testBaseObj()
39 T.destroy(); in testBaseObj()
41 T = TB.setX(2).create(); in testBaseObj()
42 assertTrue(T != null); in testBaseObj()
43 B = T; in testBaseObj()
/cts/tests/tests/hardware/src/android/hardware/camera2/cts/rs/
DScriptGraph.java319 public class ScriptBuilder<T extends Script<?>> {
321 private final Class<T> mScriptClass;
323 private ScriptBuilder(Class<T> scriptClass) { in ScriptBuilder()
327 private final ParameterMap<T> mParameterMap = new ParameterMap<T>();
342 public <K> ScriptBuilder<T> set(Script.ScriptParameter<T, K> parameter, K value) { in set() argument
352 ParameterMap<T> getParameterMap() { in getParameterMap()
356 Class<T> getScriptClass() { in getScriptClass()
385 public <T extends Script<?>> Builder chainScript(Class<T> scriptClass) { in chainScript()
388 return (new ScriptBuilder<T>(scriptClass)).buildScript(); in chainScript()
402 public <T extends Script<?>> ScriptBuilder<T> configureScript(Class<T> scriptClass) { in configureScript()
[all …]
DScript.java46 public abstract class Script<T extends android.renderscript.Script> implements UncheckedCloseable {
74 public <T> T get(Script.ScriptParameter<ScriptT, T> parameter) { in get()
77 return (T) mParameterMap.get(parameter); in get()
91 public <T> void set(Script.ScriptParameter<ScriptT, T> parameter, T value) { in set()
190 protected final T mScript;
259 protected Script(AllocationInfo inputInfo, AllocationInfo outputInfo, T rsScript) { in Script()
/cts/apps/CtsVerifier/src/com/android/cts/verifier/audio/wavelib/
DDspBufferMath.java32 static private<T extends DspBufferBase> int estimateOperandsType(T a, T b) { in estimateOperandsType()
54 static public <T extends DspBufferBase> int add(T r, T a, T b) { in add()
58 T x = a; in add()
59 T y = b; in add()
126 static public <T extends DspBufferBase> int mult(T r, T a, T b) { in mult()
130 T x = a; in mult()
131 T y = b; in mult()
209 static public <T extends DspBufferBase> int mult(T r, T a, double v) { in mult()
213 T x = a; in mult()
255 static public <T extends DspBufferBase> int set(T r, T a) { in set()
[all …]
/cts/tools/signature-tools/src/signature/compare/model/
DIDelta.java26 public interface IDelta<T> {
40 T getFrom(); in getFrom()
47 T getTo(); in getTo()
/cts/tools/signature-tools/src/signature/io/html/
DFieldByNameComparator.java24 public class FieldByNameComparator<T extends IMemberDelta<?>> implements
25 Comparator<T> {
27 public int compare(T a, T b) { in compare()
/cts/suite/audio_quality/lib/src/task/
DTaskCase.cpp67 template <typename T> bool registerGeneric( in registerGeneric()
68 typename std::map<android::String8, T>& map, in registerGeneric()
69 const android::String8& name, T& data) in registerGeneric()
71 typename std::map<android::String8, T>::iterator it; in registerGeneric()
82 template <typename T> bool findGeneric(typename std::map<android::String8, T>& map, in findGeneric()
83 const android::String8& name, T& data) in findGeneric()
86 typename std::map<android::String8, T>::iterator it; in findGeneric()
95 template <typename T> bool updateGeneric(typename std::map<android::String8, T>& map, in updateGeneric()
96 const android::String8& name, T& data) in updateGeneric()
99 typename std::map<android::String8, T>::iterator it; in updateGeneric()
[all …]
/cts/tests/tests/provider/src/android/provider/cts/
DContactsContract_TestDataBuilder.java60 public abstract class Builder<T extends Builder<?>> extends Assert {
90 public T setUri(Uri uri) { in setUri()
92 return (T)this; in setUri()
104 public T with(String key, String value) { in with()
106 return (T)this; in with()
110 public T with(String key, long value) { in with()
112 return (T)this; in with()
116 public T with(String key, byte[] value) { in with()
118 return (T)this; in with()
122 public T insert() throws Exception { in insert()
[all …]
/cts/tools/cts-reference-app-lib/src/android/cts/refapp/
DReferenceAppTestCase.java29 public class ReferenceAppTestCase<T extends Activity> extends ActivityInstrumentationTestCase2<T> {
44 public ReferenceAppTestCase(String pkg, Class<T> activityClass, int maxStartupTimeMs) { in ReferenceAppTestCase()
55 public ReferenceAppTestCase(String pkg, Class<T> activityClass) { in ReferenceAppTestCase()

1234