透過集合功能整理內容
你可以依據偏好儲存及分類內容。
ResourceInspection
在 Android Studio 即時版面配置檢查器中,顯示自訂檢視屬性。
最近更新時間 |
穩定版 |
候選版 |
Beta 版 |
Alpha 版 |
2022 年 1 月 26 日 |
1.0.1 |
- |
- |
- |
宣告依附元件
如果要為 ResourceInspection 新增依附元件,您必須將 Google Maven 存放區新增至專案。詳情請參閱 Google 的 Maven 存放區。
在應用程式或模組的 build.gradle
檔案中,新增所需構件的依附元件:
Groovy
dependencies {
implementation "androidx.resourceinspection:resourceinspection-annotation:1.0.1"
}
Kotlin
dependencies {
implementation("androidx.resourceinspection:resourceinspection-annotation:1.0.1")
}
如要進一步瞭解依附元件,請參閱「新增建構依附元件」一文。
意見回饋
您的意見可協助我們改善 Jetpack。如果您發現新問題,或是有改進這個程式庫的建議,請告訴我們。回報新問題前,請先查看這個程式庫的現有問題。只要按一下星號按鈕,即可投票給現有的問題。
建立新問題
詳情請參閱 Issue Tracker 說明文件。
1.0 版
1.0.1 版
2022 年 1 月 26 日
androidx.resourceinspection:resourceinspection-annotation:1.0.1
和 androidx.resourceinspection:resourceinspection-processor:1.0.1
發布。查看 1.0.1 版的修訂項。
修正錯誤
1.0.0 版
2021 年 11 月 3 日
androidx.resourceinspection:resourceinspection-annotation:1.0.0
和 androidx.resourceinspection:resourceinspection-processor:1.0.0
發布。查看 1.0.0 版的修訂項。
1.0.0 的主要功能
- ResourceInspection 程式庫為程式庫開發人員提供註解處理工具,可在 Android Studio 的即時版面配置檢查器中顯示自訂檢視畫面的屬性。
1.0.0-rc01 版
2021 年 10 月 27 日
androidx.resourceinspection:resourceinspection-annotation:1.0.0-rc01
和 androidx.resourceinspection:resourceinspection-processor:1.0.0-rc01
發布。1.0.0-rc01 版包含這些修訂版本。
1.0.0-beta01 版
2021 年 9 月 15 日
androidx.resourceinspection:resourceinspection-annotation:1.0.0-beta01
和 androidx.resourceinspection:resourceinspection-processor:1.0.0-beta01
發布。1.0.0-beta01 版包含這些修訂版本。
修正錯誤
1.0.0-alpha03 版
2021 年 6 月 30 日
androidx.resourceinspection:resourceinspection-annotation:1.0.0-alpha03
和 androidx.resourceinspection:resourceinspection-processor:1.0.0-alpha03
發布。1.0.0-alpha03 版包含此連結所列的修訂項目。
修正錯誤
- 修正產生的程式碼中造成版面配置檢查器無法讀取檢視屬性的錯誤。(Ic7507)
1.0.0-alpha02 版
2021 年 6 月 2 日
androidx.resourceinspection:resourceinspection-annotation:1.0.0-alpha02
和 androidx.resourceinspection:resourceinspection-processor:1.0.0-alpha02
發布。1.0.0-alpha02 版包含此連結所列的修訂項目。
API 相關異動
1.0.0-alpha01 版
2021 年 3 月 24 日
androidx.resourceinspection:resourceinspection-annotation:1.0.0-alpha01
和 androidx.resourceinspection:resourceinspection-processor:1.0.0-alpha01
發布。1.0.0-alpha01 版包含此連結所列的修訂項目。
新功能
資源檢查程式庫提供簡單好上手的程式庫,可讓程式庫開發人員在 Android Studio 的即時版面配置檢查器中呈現自訂檢視畫面的屬性。初始版本為 1.0.0-alpha01
。
這個頁面中的內容和程式碼範例均受《內容授權》中的授權所規範。Java 與 OpenJDK 是 Oracle 和/或其關係企業的商標或註冊商標。
上次更新時間:2025-07-27 (世界標準時間)。
[[["容易理解","easyToUnderstand","thumb-up"],["確實解決了我的問題","solvedMyProblem","thumb-up"],["其他","otherUp","thumb-up"]],[["缺少我需要的資訊","missingTheInformationINeed","thumb-down"],["過於複雜/步驟過多","tooComplicatedTooManySteps","thumb-down"],["過時","outOfDate","thumb-down"],["翻譯問題","translationIssue","thumb-down"],["示例/程式碼問題","samplesCodeIssue","thumb-down"],["其他","otherDown","thumb-down"]],["上次更新時間:2025-07-27 (世界標準時間)。"],[],[],null,["# Resource Inspection\n\nResourceInspection\n==================\n\nAPI Reference \n[androidx.resourceinspection.annotation](/reference/kotlin/androidx/resourceinspection/annotation/package-summary) \nSurface the attributes of custom views in Android Studio's Live Layout Inspector. \n\n| Latest Update | Stable Release | Release Candidate | Beta Release | Alpha Release |\n|------------------|--------------------------------------------------------------|-------------------|--------------|---------------|\n| January 26, 2022 | [1.0.1](/jetpack/androidx/releases/resourceinspection#1.0.1) | - | - | - |\n\nDeclaring dependencies\n----------------------\n\nTo add a dependency on ResourceInspection, you must add the Google Maven repository to your\nproject. Read [Google's Maven repository](/studio/build/dependencies#google-maven)\nfor more information.\n\nAdd the dependencies for the artifacts you need in the `build.gradle` file for\nyour app or module: \n\n### Groovy\n\n```groovy\ndependencies {\n implementation \"androidx.resourceinspection:resourceinspection-annotation:1.0.1\"\n}\n```\n\n### Kotlin\n\n```kotlin\ndependencies {\n implementation(\"androidx.resourceinspection:resourceinspection-annotation:1.0.1\")\n}\n```\n\nFor more information about dependencies, see [Add build dependencies](/studio/build/dependencies).\n\nFeedback\n--------\n\nYour feedback helps make Jetpack better. Let us know if you discover new issues or have\nideas for improving this library. Please take a look at the\n[existing issues](https://issuetracker.google.com/issues?q=componentid:1033483%20status:open)\nin this library before you create a new one. You can add your vote to an existing issue by\nclicking the star button.\n\n[Create a new issue](https://issuetracker.google.com/issues/new?component=1033483&template=1565569)\n\nSee the [Issue Tracker documentation](https://developers.google.com/issue-tracker)\nfor more information.\n\nVersion 1.0\n-----------\n\n### Version 1.0.1\n\nJanuary 26, 2022\n\n`androidx.resourceinspection:resourceinspection-annotation:1.0.1` and `androidx.resourceinspection:resourceinspection-processor:1.0.1` are released. [Version 1.0.1 contains these commits.](https://android.googlesource.com/platform/frameworks/support/+log/255d9759ff9495ea552d71b415bf638a02046780..8ae940536431022e180d2b13f8981184dc60fa74/resourceinspection)\n\n**Bug Fixes**\n\n- Added package documentation\n\n### Version 1.0.0\n\nNovember 3, 2021\n\n`androidx.resourceinspection:resourceinspection-annotation:1.0.0` and `androidx.resourceinspection:resourceinspection-processor:1.0.0` are released. [Version 1.0.0 contains these commits.](https://android.googlesource.com/platform/frameworks/support/+log/c38bf8cba2f6d60f9cceb03adcb56ff57f793b27..255d9759ff9495ea552d71b415bf638a02046780/resourceinspection)\n\n**Major features of 1.0.0**\n\n- The ResourceInspection library provides an annotation processor for library developers to surface the attributes of custom views in Android Studio's [Live Layout Inspector](/studio/debug/layout-inspector#4-0-0-live-layout-inspector).\n\n### Version 1.0.0-rc01\n\nOctober 27, 2021\n\n`androidx.resourceinspection:resourceinspection-annotation:1.0.0-rc01` and `androidx.resourceinspection:resourceinspection-processor:1.0.0-rc01` are released. [Version 1.0.0-rc01 contains these commits.](https://android.googlesource.com/platform/frameworks/support/+log/1a3dcfb231517d6104969f17063fcc6c97ba6eeb..c38bf8cba2f6d60f9cceb03adcb56ff57f793b27/resourceinspection)\n\n- No changes since 1.0.0-beta01\n\n### Version 1.0.0-beta01\n\nSeptember 15, 2021\n\n`androidx.resourceinspection:resourceinspection-annotation:1.0.0-beta01` and `androidx.resourceinspection:resourceinspection-processor:1.0.0-beta01` are released. [Version 1.0.0-beta01 contains these commits.](https://android.googlesource.com/platform/frameworks/support/+log/19ae3a88ff0824d615355b492cb56049e16991f2..1a3dcfb231517d6104969f17063fcc6c97ba6eeb/resourceinspection)\n\n**Bug Fixes**\n\n- Fixed crash on non-existent attributes ([I87df0](https://android-review.googlesource.com/#/q/I87df0c0c68f04b32274eaedd65b5a7ab3c56b562))\n- Fixed crash when compiling against an older SDK ([Ie8a1e](https://android-review.googlesource.com/#/q/Ie8a1eafcae62aa98330fc7af89474a32c61faafc))\n- Added validation for int enums and flags ([Ic7ecf](https://android-review.googlesource.com/#/q/Ic7ecf3386c04d133f74b858953d747cacfecfc5a))\n\n### Version 1.0.0-alpha03\n\nJune 30, 2021\n\n`androidx.resourceinspection:resourceinspection-annotation:1.0.0-alpha03` and `androidx.resourceinspection:resourceinspection-processor:1.0.0-alpha03` are released. [Version 1.0.0-alpha03 contains these commits.](https://android.googlesource.com/platform/frameworks/support/+log/86ff5b4bb956431ec884586ce0aea0127e189ec4..19ae3a88ff0824d615355b492cb56049e16991f2/resourceinspection)\n\n**Bug Fixes**\n\n- Fix a bug in generated code that prevented the Layout Inspector from reading view attributes. ([Ic7507](https://android-review.googlesource.com/#/q/Ic75075f21dafdf5cd12b714eff3a42e0fab17bbc))\n\n### Version 1.0.0-alpha02\n\nJune 2, 2021\n\n`androidx.resourceinspection:resourceinspection-annotation:1.0.0-alpha02` and `androidx.resourceinspection:resourceinspection-processor:1.0.0-alpha02` are released. [Version 1.0.0-alpha02 contains these commits.](https://android.googlesource.com/platform/frameworks/support/+log/5c42896eb6591b09e3952030fb7ea8d9b8c42713..86ff5b4bb956431ec884586ce0aea0127e189ec4/resourceinspection)\n\n**API Changes**\n\n- Improved AppCompat support ([I2d738](https://android-review.googlesource.com/#/q/I2d7387a017585bcea14a8d8a857b9b60930bc1c5), [b/188446121](https://issuetracker.google.com/issues/188446121))\n\n### Version 1.0.0-alpha01\n\nMarch 24, 2021\n\n`androidx.resourceinspection:resourceinspection-annotation:1.0.0-alpha01` and `androidx.resourceinspection:resourceinspection-processor:1.0.0-alpha01` are released. [Version 1.0.0-alpha01 contains these commits.](https://android.googlesource.com/platform/frameworks/support/+log/5c42896eb6591b09e3952030fb7ea8d9b8c42713/resourceinspection)\n\n**New Features**\n\nThe Resource Inspection library provides a convenient way for library developers to surface the attributes of custom views in Android Studio's [Live Layout Inspector](/studio/debug/layout-inspector#4-0-0-live-layout-inspector). This initial release is `1.0.0-alpha01`."]]