DeviceReference
    
    
      
    
    
      
      קל לארגן דפים בעזרת אוספים
    
    
      
      אפשר לשמור ולסווג תוכן על סמך ההעדפות שלך.
    
  
  
      
    
  
  
  
  
  
    
  
  
    
    
    
    
    
    
      
      
        DeviceReference היא הפשטה של API שמאפשרת לספק ארגומנט device ל-method באמצעות אחד מסוגי המזהים הבאים:
        
          - מזהה מספרי של משאב API.
- מזהי חומרה בעולם האמיתי, כמו מספר IMEI, השייכים למכשיר שיוצרו.
בשיטות שפועלות במכשירים, מוגדר סוג הפרמטר DeviceReference כפרמטר כי הוא גמיש יותר למתקשר. מידע נוסף על מזהי מכשירים זמין במאמר מזהים.
      
      
        
          
            
              | ייצוג JSON | 
          
          
            
              | {
  // Union field devicecan be only one of the following:
  "deviceId": string,
  "deviceIdentifier": {
    object (DeviceIdentifier)
  }
  // End of list of possible types for union fielddevice.
} | 
          
        
      
      
        
          
            
              | שדות | 
          
          
            
              | שדה איחוד device. חובה. המזהה הייחודי של המכשיר.deviceיכול להיות רק אחת מהאפשרויות הבאות: | 
            
              | deviceId | string (int64 format)
 המזהה של המכשיר. | 
            
              | deviceIdentifier | object (DeviceIdentifier)
 מזהי החומרה של המכשיר. | 
          
        
      
    
  
  
  
  
 
  
    
    
      
       
    
    
  
  
  אלא אם צוין אחרת, התוכן של דף זה הוא ברישיון Creative Commons Attribution 4.0 ודוגמאות הקוד הן ברישיון Apache 2.0. לפרטים, ניתן לעיין במדיניות האתר Google Developers. Java הוא סימן מסחרי רשום של חברת Oracle ו/או של השותפים העצמאיים שלה.
  עדכון אחרון: 2025-07-25 (שעון UTC).
  
  
  
    
      [null,null,["עדכון אחרון: 2025-07-25 (שעון UTC)."],[],["A `DeviceReference` is used as a device argument in methods, accepting either a numeric API resource ID (`deviceId`) or real-world hardware IDs (`deviceIdentifier`) like IMEI.  The JSON representation uses a union field named `device` that contains either a `deviceId` string (int64 format) or a `deviceIdentifier` object, which holds the device's hardware IDs. Methods use this type for increased flexibility in identifying devices.\n"]]