Classe GCKNetworkAddress
Oggetto che rappresenta un indirizzo IP di rete.
Questo oggetto è immutabile.
- Dal
- 4,2
Eredita NSObject, <NSCOPY> e <NSSecureCoding>.
|
GCKNetworkAddressType | type |
| Il tipo di indirizzo. Altro...
|
|
NSString * | ipAddress |
| L'indirizzo IP. Altro...
|
|
NSData * | addressData |
| L'indirizzo di rete come NSData contenente la struttura dell'indirizzo appropriata (ad esempio, struct in_addr o struct in6_addr). Altro...
|
|
Non è consentito utilizzare l'inizializzazione predefinita.
- (instancetype) initWithType: |
|
(GCKNetworkAddressType) |
type |
ipAddress: |
|
(nullable NSString *) |
ipAddress |
|
|
| |
Crea un GCKNetworkAddress con il tipo di indirizzo e l'indirizzo IP specificati.
- Parameters
-
type | The address type. |
ipAddress | The IP address, in textual form. May be nil to indicate the wildcard ("any") address. |
- (instancetype) initWithType: |
|
(GCKNetworkAddressType) |
type |
addressData: |
|
(nullable NSData *) |
addressData |
|
|
| |
Crea un GCKNetworkAddress con il tipo di indirizzo e l'indirizzo non elaborati specificati.
- Parameters
-
type | The address type. |
addressData | An NSData object containing the appropriate address structure (e.g., struct in_addr or struct in6_addr). For the GCKNNetworkAddressTypeIPC, the data is expected to be a UTF8 encoding. |
Crea un indirizzo con caratteri jolly del tipo specificato.
Crea un indirizzo di loopback del tipo specificato.
Crea un indirizzo di trasmissione IPv4.
- (GCKNetworkAddressType) type |
|
readnonatomicassign |
L'indirizzo di rete come NSData contenente la struttura dell'indirizzo appropriata (ad esempio, struct in_addr o struct in6_addr).
Per il tipo di indirizzo IPC, questo campo utilizza una codifica UTF8.
Salvo quando diversamente specificato, i contenuti di questa pagina sono concessi in base alla licenza Creative Commons Attribution 4.0, mentre gli esempi di codice sono concessi in base alla licenza Apache 2.0. Per ulteriori dettagli, consulta le norme del sito di Google Developers. Java è un marchio registrato di Oracle e/o delle sue consociate.
Ultimo aggiornamento 2023-12-02 UTC.
[null,null,["Ultimo aggiornamento 2023-12-02 UTC."],[[["The `GCKNetworkAddress` class represents a network IP address and is immutable."],["It provides methods to construct network addresses of various types, including IPv4, IPv6, and IPC."],["You can obtain the address type, IP address string, and raw address data from instances of this class."],["The default initializer is not allowed; you must use designated initializers to create instances."]]],["The `GCKNetworkAddress` class represents an immutable network IP address. Key actions include: constructing addresses with specified type and IP/raw address using `initWithType:ipAddress:` or `initWithType:addressData:`, creating wildcard addresses with `wildcardAddressOfType:`, loopback addresses with `loopbackAddressOfType:`, or IPv4/IPv6/IPC addresses with corresponding methods. It has properties that return the address's type, IP address, and network data representation. The default initializer is not allowed.\n"]]