Python 2.7 はサポートが終了しており、2026 年 1 月 31 日に
非推奨になります。非推奨になると、過去に組織のポリシーを使用して以前のランタイムのデプロイを再度有効にしていた場合でも、Python 2.7 アプリケーションをデプロイできなくなります。既存の Python 2.7 アプリケーションは、
非推奨日以降も引き続き実行され、トラフィックを受信します。
サポートされている最新バージョンの Python に移行することをおすすめします。
FacetOptions クラス
コレクションでコンテンツを整理
必要に応じて、コンテンツの保存と分類を行います。
FacetOptions
クラスは、クエリのファセット結果を処理するためのオプションを提供します。
FacetOptions
は、google.appengine.api.search
モジュールで定義されます。
はじめに
FacetOptions
クラスは、クエリのファセット結果を処理するためのオプションを提供します。オプションには検出するファセットの数、各ファセットの値の数、およびファセットの計算に考慮する結果の奥行きがあります。
コンストラクタ
FacetOptions
クラスのコンストラクタは、次のように定義されます。
-
facet_option = FacetOptions(discovery_limit=5, discovery_value_limit=None, depth=None)
クエリのファセット結果を処理するためのオプションを指定します。
-
引数
- discovery_limit
- discovery_value_limit
- depth
結果値
FacetOptions
クラスの新しいインスタンス。
例外
- TypeError
不明な属性が渡された場合。
- ValueError
いずれかのパラメータが無効な値(負の奥行きなど)である場合。
プロパティ
FacetOptions
クラスのインスタンスには次のプロパティがあります。
- discovery_limit
ファセット検出が有効にされている場合に、検出するファセット数。None の場合、ファセット検出は無効になります。
- discovery_value_limit
検出された上位ファセットのそれぞれについて検出する値の数。
- depth
ファセット情報を収集するために評価する、クエリ結果のドキュメント数。
特に記載のない限り、このページのコンテンツはクリエイティブ・コモンズの表示 4.0 ライセンスにより使用許諾されます。コードサンプルは Apache 2.0 ライセンスにより使用許諾されます。詳しくは、Google Developers サイトのポリシーをご覧ください。Java は Oracle および関連会社の登録商標です。
最終更新日 2025-09-04 UTC。
[[["わかりやすい","easyToUnderstand","thumb-up"],["問題の解決に役立った","solvedMyProblem","thumb-up"],["その他","otherUp","thumb-up"]],[["わかりにくい","hardToUnderstand","thumb-down"],["情報またはサンプルコードが不正確","incorrectInformationOrSampleCode","thumb-down"],["必要な情報 / サンプルがない","missingTheInformationSamplesINeed","thumb-down"],["翻訳に関する問題","translationIssue","thumb-down"],["その他","otherDown","thumb-down"]],["最終更新日 2025-09-04 UTC。"],[[["\u003cp\u003e\u003ccode\u003eFacetOptions\u003c/code\u003e class is used to configure the processing of facet results from a query.\u003c/p\u003e\n"],["\u003cp\u003eThe class allows you to specify the number of facets, values per facet, and the depth of results to include.\u003c/p\u003e\n"],["\u003cp\u003eThis API is applicable to first-generation runtimes and offers options for upgrading to second-generation runtimes, with a migration guide available for Python 3 runtime.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003eFacetOptions\u003c/code\u003e is located in the \u003ccode\u003egoogle.appengine.api.search\u003c/code\u003e module.\u003c/p\u003e\n"]]],[],null,["# The FacetOptions Class\n\nClass `FacetOptions` provides options for processing facet results of a query.\n| This API is supported for first-generation runtimes and can be used when [upgrading to corresponding second-generation runtimes](/appengine/docs/standard/\n| python3\n|\n| /services/access). If you are updating to the App Engine Python 3 runtime, refer to the [migration guide](/appengine/migration-center/standard/migrate-to-second-gen/python-differences) to learn about your migration options for legacy bundled services.\n\n`FacetOptions` is defined in the `google.appengine.api.search` module.\n\nIntroduction\n------------\n\nClass `FacetOptions` provides options for processing facet results of a\nquery. Options include number of facets to discover, number of values for each facet and the depth\nof the result to be considered for facet computation.\n\nConstructor\n-----------"]]