SearchMode
קל לארגן דפים בעזרת אוספים
אפשר לשמור ולסווג תוכן על סמך ההעדפות שלך.
מצב הגדרת התנהגות החיפוש, תוך החלפה של זמן האחזור לעומת איכות הפתרון. בכל הסוגים, נאכף התאריך האחרון לשליחת בקשות.
טיפוסים בני מנייה (enums) |
SEARCH_MODE_UNSPECIFIED |
מצב חיפוש לא מוגדר, שווה ערך ל-RETURN_FAST . |
RETURN_FAST |
מפסיקים את החיפוש אחרי שמוצאים את הפתרון הטוב הראשון. |
CONSUME_ALL_AVAILABLE_TIME |
הקדישו את כל הזמן הזמין לחיפוש פתרונות טובים יותר. |
אלא אם צוין אחרת, התוכן של דף זה הוא ברישיון Creative Commons Attribution 4.0 ודוגמאות הקוד הן ברישיון Apache 2.0. לפרטים, ניתן לעיין במדיניות האתר Google Developers. Java הוא סימן מסחרי רשום של חברת Oracle ו/או של השותפים העצמאיים שלה.
עדכון אחרון: 2025-08-31 (שעון UTC).
[null,null,["עדכון אחרון: 2025-08-31 (שעון UTC)."],[[["\u003cp\u003eSearch mode determines the balance between speed and the quality of solutions found.\u003c/p\u003e\n"],["\u003cp\u003eThree options are available: \u003ccode\u003eRETURN_FAST\u003c/code\u003e prioritizes speed, \u003ccode\u003eCONSUME_ALL_AVAILABLE_TIME\u003c/code\u003e prioritizes solution quality, and \u003ccode\u003eSEARCH_MODE_UNSPECIFIED\u003c/code\u003e defaults to \u003ccode\u003eRETURN_FAST\u003c/code\u003e.\u003c/p\u003e\n"],["\u003cp\u003eAll search modes adhere to the overall request deadline.\u003c/p\u003e\n"]]],["The core content defines search modes that balance latency and solution quality, all adhering to a global deadline. `RETURN_FAST` mode prioritizes speed, halting the search after the initial satisfactory solution. Conversely, `CONSUME_ALL_AVAILABLE_TIME` mode maximizes search duration to improve solution quality. `SEARCH_MODE_UNSPECIFIED` is the default, mirroring the behavior of `RETURN_FAST`. These modes dictate how the system allocates time to finding solutions.\n"],null,["# SearchMode\n\nMode defining the behavior of the search, trading off latency versus solution quality. In all modes, the global request deadline is enforced.\n\n| Enums ||\n|------------------------------|--------------------------------------------------------------|\n| `SEARCH_MODE_UNSPECIFIED` | Unspecified search mode, equivalent to `RETURN_FAST`. |\n| `RETURN_FAST` | Stop the search after finding the first good solution. |\n| `CONSUME_ALL_AVAILABLE_TIME` | Spend all the available time to search for better solutions. |"]]