Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Migrate "Add Features with Contingent Values" to Compose #283

Merged
merged 14 commits into from
Jan 9, 2025
3 changes: 2 additions & 1 deletion samples/add-features-with-contingent-values/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,9 @@ The mobile geodatabase contains birds nests in the Fillmore area, defined with c

01smito01 marked this conversation as resolved.
Show resolved Hide resolved
01smito01 marked this conversation as resolved.
Show resolved Hide resolved
## Additional information

This sample uses the GeoCompose Toolkit module to be able to implement a Composable MapView.
01smito01 marked this conversation as resolved.
Show resolved Hide resolved
Learn more about contingent values and how to utilize them on the [ArcGIS Pro documentation](https://pro.arcgis.com/en/pro-app/latest/help/data/geodatabases/overview/contingent-values.htm).

## Tags

coded values, contingent values, feature table, geodatabase
coded values, contingent values, feature table, geodatabase, geoviewcompose, toolkit
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
coded values, contingent values, feature table, geodatabase, geoviewcompose, toolkit
coded values, contingent values, feature table, geodatabase, geoview, mapview, compose, toolkit

Copy link
Collaborator Author

@01smito01 01smito01 Dec 11, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

geoviewcompose and toolkit are the tags the epic recommends to add. I don't think they need to be changed.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I find geoviewcompose odd as a tag but maybe there is a good reason for it. \cc @shubham7109

Copy link
Collaborator

@shubham7109 shubham7109 Dec 19, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@gunt0001 The tag here was meant to match the geoviewcompose Toolkit package name. I see it as little odd too, and I recall tags must use lowercase. Alternatively, a valid option could be to use geoview-compose to match the Toolkit module name instead. (Quick test looks like the PR checker would be happy.)

\cc @TADraeseke Thoughts?

84 changes: 44 additions & 40 deletions samples/add-features-with-contingent-values/README.metadata.json
Original file line number Diff line number Diff line change
@@ -1,42 +1,46 @@
{
"category": "Edit and Manage Data",
"description": "Create and add features whose attribute values satisfy a predefined set of contingencies.",
"formal_name": "AddFeaturesWithContingentValues",
"ignore": false,
"images": [
"add-features-with-contingent-values.png"
],
"keywords": [
"coded values",
"contingent values",
"feature table",
"geodatabase",
"ArcGISFeatureTable",
"CodedValue",
"CodedValueDomain",
"ContingencyConstraintViolation",
"ContingentCodedValue",
"ContingentRangeValue",
"ContingentValuesDefinition",
"ContingentValuesResult"
],
"language": "kotlin",
"redirect_from": [
"/android/latest/sample-code/add-features-with-contingent-values.htm"
],
"relevant_apis": [
"ArcGISFeatureTable",
"CodedValue",
"CodedValueDomain",
"ContingencyConstraintViolation",
"ContingentCodedValue",
"ContingentRangeValue",
"ContingentValuesDefinition",
"ContingentValuesResult"
],
"snippets": [
"src/main/java/com/esri/arcgismaps/sample/addfeatureswithcontingentvalues/MainActivity.kt",
"src/main/java/com/esri/arcgismaps/sample/addfeatureswithcontingentvalues/DownloadActivity.kt"
],
"title": "Add features with contingent values"
"category": "Edit and Manage Data",
"description": "Create and add features whose attribute values satisfy a predefined set of contingencies.",
"formal_name": "AddFeaturesWithContingentValues",
"ignore": false,
"images": [
"add-features-with-contingent-values.png"
],
"keywords": [
"coded values",
"contingent values",
"feature table",
"geodatabase",
"geoviewcompose",
"toolkit",
"ArcGISFeatureTable",
"CodedValue",
"CodedValueDomain",
"ContingencyConstraintViolation",
"ContingentCodedValue",
"ContingentRangeValue",
"ContingentValuesDefinition",
"ContingentValuesResult"
],
"language": "kotlin",
"redirect_from": [
"/android/latest/sample-code/add-features-with-contingent-values.htm"
],
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Redirects are helpful to use when a sample name (underlying URL) has changed. In this case, the sample name is the same but migrated to compose. No need to use redirect here:

Suggested change
"redirect_from": [
"/android/latest/sample-code/add-features-with-contingent-values.htm"
],
"redirect_from": "",

"relevant_apis": [
"ArcGISFeatureTable",
"CodedValue",
"CodedValueDomain",
"ContingencyConstraintViolation",
"ContingentCodedValue",
"ContingentRangeValue",
"ContingentValuesDefinition",
"ContingentValuesResult"
],
"snippets": [
"src/main/java/com/esri/arcgismaps/sample/addfeatureswithcontingentvalues/components/MapViewModel.kt",
"src/main/java/com/esri/arcgismaps/sample/addfeatureswithcontingentvalues/DownloadActivity.kt",
"src/main/java/com/esri/arcgismaps/sample/addfeatureswithcontingentvalues/MainActivity.kt",
"src/main/java/com/esri/arcgismaps/sample/addfeatureswithcontingentvalues/screens/MainScreen.kt"
],
"title": "Add features with contingent values"
}
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
plugins {
alias(libs.plugins.arcgismaps.android.library)
alias(libs.plugins.arcgismaps.android.library.compose)
alias(libs.plugins.arcgismaps.kotlin.sample)
alias(libs.plugins.gradle.secrets)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,6 @@
android:name=".DownloadActivity"
android:exported="true"
android:label="@string/add_features_with_contingent_values_app_name">


<meta-data
android:name="android.app.lib_name"
android:value="" />
</activity>
<activity
android:name=".MainActivity"
Expand Down
Loading
Loading