Library API guidelines

Contents

  • Introduction
  • Modules
    • Packaging and naming
    • Choosing a
    • Kotlin extension libraries
  • Platform compatibility API patterns
    • Static shims (ex. ViewCompat)
    • Wrapper (ex. AccessibilityNodeInfoCompat)
    • Standalone (ex. ArraySet, Fragment)
    • Standalone JAR library (no Android dependencies)
  • Implementing compatibility
    • Referencing new APIs
    • Delegating to API-specific implementations
    • Inter-process communication
  • Deprecation and removal
    • Deprecation ()
    • Soft removal (@removed)
    • Hard removal
    • For entire artifacts
  • Resources
    • Defining new resources
    • Public resources
    • Manifest entries ()
  • Dependencies
    • Versioned artifacts
    • Non-public APIs
    • Third-party libraries
    • Types of dependencies
    • System health
    • Open-source compatibility
  • More API guidelines
    • Annotations
    • Experimental APIs
    • Restricted APIs
    • Constructors
    • Asynchronous work
    • Kotlin
  • Testing Guidelines
    • Do not Mock, AndroidX
  • Android Lint Guidelines
    • Suppression vs Baselines
  • Metalava API Lint
  • Build Output Guidelines
    • Invoking build output validation
    • Exempting new build output messages
  • Behavior changes
    • Changes that affect API documentation
    • High-risk beh