| // OBEX library |
| package { |
| default_applicable_licenses: ["obex_license"], |
| } |
| |
| // Added automatically by a large-scale-change that took the approach of |
| // 'apply every license found to every target'. While this makes sure we respect |
| // every license restriction, it may not be entirely correct. |
| // |
| // e.g. GPL in an MIT project might only apply to the contrib/ directory. |
| // |
| // Please consider splitting the single license below into multiple licenses, |
| // taking care not to lose any license_kind information, and overriding the |
| // default license using the 'licenses: [...]' property on targets as needed. |
| // |
| // For unused files, consider creating a 'fileGroup' with "//visibility:private" |
| // to attach the license to, and including a comment whether the files may be |
| // used in the current project. |
| // See: http://go/android-license-faq |
| license { |
| name: "obex_license", |
| visibility: [":__subpackages__"], |
| license_kinds: [ |
| "SPDX-license-identifier-Apache-2.0", |
| "SPDX-license-identifier-BSD", |
| ], |
| license_text: [ |
| "LICENSE", |
| ], |
| } |
| |
| java_library { |
| name: "com.android.obex", |
| |
| srcs: ["**/*.java"], |
| apex_available: ["com.android.bt"], |
| sdk_version: "module_current", |
| min_sdk_version: "Tiramisu", |
| |
| errorprone: { |
| enabled: true, |
| javacflags: [ |
| "-Xep:AlmostJavadoc:ERROR", |
| "-Xep:AlreadyChecked:ERROR", |
| "-Xep:BadImport:ERROR", |
| "-Xep:CatchAndPrintStackTrace:ERROR", |
| "-Xep:CatchFail:ERROR", |
| "-Xep:CheckReturnValue:ERROR", |
| "-Xep:ClassCanBeStatic:ERROR", |
| "-Xep:DateFormatConstant:ERROR", |
| "-Xep:DirectInvocationOnMock:ERROR", |
| "-Xep:DuplicateBranches:ERROR", |
| "-Xep:EmptyBlockTag:ERROR", |
| "-Xep:EmptyCatch:ERROR", |
| "-Xep:EnumOrdinal:ERROR", |
| "-Xep:EqualsGetClass:ERROR", |
| "-Xep:EqualsHashCode:ERROR", |
| "-Xep:EqualsIncompatibleType:ERROR", |
| "-Xep:FallThrough:ERROR", |
| "-Xep:Finalize:ERROR", |
| "-Xep:ForEachIterable:ERROR", |
| "-Xep:FutureReturnValueIgnored:ERROR", |
| "-Xep:GuardedBy:ERROR", |
| "-Xep:HidingField:ERROR", |
| "-Xep:InconsistentHashCode:ERROR", |
| "-Xep:InlineFormatString:ERROR", |
| "-Xep:InlineMeInliner:ERROR", |
| "-Xep:InvalidBlockTag:ERROR", |
| "-Xep:InvalidInlineTag:ERROR", |
| "-Xep:InvalidParam:ERROR", |
| "-Xep:JavaUtilDate:ERROR", |
| "-Xep:JdkObsolete:ERROR", |
| "-Xep:LockOnNonEnclosingClassLiteral:ERROR", |
| "-Xep:LongFloatConversion:ERROR", |
| "-Xep:LoopOverCharArray:ERROR", |
| "-Xep:MethodCanBeStatic:ERROR", |
| "-Xep:MissingCasesInEnumSwitch:ERROR", |
| "-Xep:MixedMutabilityReturnType:ERROR", |
| "-Xep:MockNotUsedInProduction:ERROR", |
| "-Xep:ModifiedButNotUsed:ERROR", |
| "-Xep:ModifyCollectionInEnhancedForLoop:ERROR", |
| "-Xep:NarrowCalculation:ERROR", |
| "-Xep:NarrowingCompoundAssignment:ERROR", |
| "-Xep:NonApiType:ERROR", |
| "-Xep:NonAtomicVolatileUpdate:ERROR", |
| "-Xep:NonCanonicalType:ERROR", |
| "-Xep:NotJavadoc:ERROR", |
| "-Xep:NullablePrimitive:ERROR", |
| "-Xep:NullableVoid:ERROR", |
| "-Xep:ObjectEqualsForPrimitives:ERROR", |
| "-Xep:OperatorPrecedence:ERROR", |
| "-Xep:RedundantControlFlow:ERROR", |
| "-Xep:ReferenceEquality:ERROR", |
| "-Xep:ReturnAtTheEndOfVoidFunction:ERROR", |
| "-Xep:ReturnFromVoid:ERROR", |
| "-Xep:StaticAssignmentInConstructor:ERROR", |
| "-Xep:StaticGuardedByInstance:ERROR", |
| "-Xep:StringCaseLocaleUsage:ERROR", |
| "-Xep:StringCharset:ERROR", |
| "-Xep:SynchronizeOnNonFinalField:ERROR", |
| "-Xep:ThreadJoinLoop:ERROR", |
| "-Xep:ToStringReturnsNull:ERROR", |
| "-Xep:TruthConstantAsserts:ERROR", |
| "-Xep:TruthIncompatibleType:ERROR", |
| "-Xep:UndefinedEquals:ERROR", |
| "-Xep:UnnecessaryAssignment:ERROR", |
| "-Xep:UnnecessaryAsync:ERROR", |
| "-Xep:UnnecessaryStringBuilder:ERROR", |
| "-Xep:UnrecognisedJavadocTag:ERROR", |
| "-Xep:UnusedMethod:ERROR", |
| "-Xep:UnusedNestedClass:ERROR", |
| "-Xep:UnusedVariable:ERROR", |
| "-Xep:VariableNameSameAsType:ERROR", |
| "-Xep:WaitNotInLoop:ERROR", |
| "-Xep:WakelockReleasedDangerously:ERROR", |
| ], |
| }, |
| } |