Lines Matching refs:address

33  * This class represents an Internet Protocol version 4 (IPv4) address.
43 * Textual representation of IPv4 address used as input to methods
55 * address.
57 * <p> When a three part address is specified, the last part is
59 * bytes of the network address. This makes the three part address
63 * <p> When a two part address is supplied, the last part is
65 * bytes of the network address. This makes the two part address
70 * the network address without any byte rearrangement.
106 holder().address = 0;
115 int address = addr[3] & 0xFF;
116 address |= ((addr[2] << 8) & 0xFF00);
117 address |= ((addr[1] << 16) & 0xFF0000);
118 address |= ((addr[0] << 24) & 0xFF000000);
119 holder().address = address;
123 Inet4Address(String hostName, int address) {
126 holder().address = address;
141 inet.holder().address = holder().getAddress();
156 * IP multicast address. IP multicast address is a Class D
157 * address i.e first four bits of the address are 1110.
159 * an IP multicast address
167 * Utility routine to check if the InetAddress in a wildcard address.
169 * a wildcard address.
177 * Utility routine to check if the InetAddress is a loopback address.
180 * a loopback address; or false otherwise.
191 * Utility routine to check if the InetAddress is an link local address.
194 * a link local address; or false if address is not a link local unicast address.
202 int address = holder().getAddress();
203 return (((address >>> 24) & 0xFF) == 169)
204 && (((address >>> 16) & 0xFF) == 254);
208 * Utility routine to check if the InetAddress is a site local address.
211 * a site local address; or false if address is not a site local unicast address.
219 int address = holder().getAddress();
220 return (((address >>> 24) & 0xFF) == 10)
221 || ((((address >>> 24) & 0xFF) == 172)
222 && (((address >>> 16) & 0xF0) == 16))
223 || ((((address >>> 24) & 0xFF) == 192)
224 && (((address >>> 16) & 0xFF) == 168));
228 * Utility routine to check if the multicast address has global scope.
230 * @return a <code>boolean</code> indicating if the address has
231 * is a multicast address of global scope, false if it is not
232 * of global scope or it is not a multicast address
244 * Utility routine to check if the multicast address has node scope.
246 * @return a <code>boolean</code> indicating if the address has
247 * is a multicast address of node-local scope, false if it is not
248 * of node-local scope or it is not a multicast address
257 * Utility routine to check if the multicast address has link scope.
259 * @return a <code>boolean</code> indicating if the address has
260 * is a multicast address of link-local scope, false if it is not
261 * of link-local scope or it is not a multicast address
266 int address = holder().getAddress();
267 return (((address >>> 24) & 0xFF) == 224)
268 && (((address >>> 16) & 0xFF) == 0)
269 && (((address >>> 8) & 0xFF) == 0);
273 * Utility routine to check if the multicast address has site scope.
275 * @return a <code>boolean</code> indicating if the address has
276 * is a multicast address of site-local scope, false if it is not
277 * of site-local scope or it is not a multicast address
282 int address = holder().getAddress();
283 return (((address >>> 24) & 0xFF) == 239)
284 && (((address >>> 16) & 0xFF) == 255);
288 * Utility routine to check if the multicast address has organization scope.
290 * @return a <code>boolean</code> indicating if the address has
291 * is a multicast address of organization-local scope,
293 * or it is not a multicast address
298 int address = holder().getAddress();
299 return (((address >>> 24) & 0xFF) == 239)
300 && (((address >>> 16) & 0xFF) >= 192)
301 && (((address >>> 16) & 0xFF) <= 195);
305 * Returns the raw IP address of this <code>InetAddress</code>
307 * byte of the address is in <code>getAddress()[0]</code>.
309 * @return the raw IP address of this object.
312 int address = holder().getAddress();
315 addr[0] = (byte) ((address >>> 24) & 0xFF);
316 addr[1] = (byte) ((address >>> 16) & 0xFF);
317 addr[2] = (byte) ((address >>> 8) & 0xFF);
318 addr[3] = (byte) (address & 0xFF);
323 * Returns the IP address string in textual presentation form.
325 * @return the raw IP address in a string format.
333 * Returns a hashcode for this IP address.
335 * @return a hash code value for this IP address.
344 * not <code>null</code> and it represents the same IP address as
348 * address if the length of the byte arrays returned by
364 * Converts IPv4 binary address into a string suitable for presentation.
366 * @param src a byte array representing an IPv4 numeric address
367 * @return a String representing the IPv4 address in