371 |
* thansferred in this form in |
* thansferred in this form in |
372 |
* {@link write_Object(org.omg.CORBA.Object)}. |
* {@link write_Object(org.omg.CORBA.Object)}. |
373 |
* |
* |
374 |
|
* If the stream contains a null value, the Id and Internet fields become |
375 |
|
* equal to null. Otherwise Id contains some string (possibly |
376 |
|
* empty). |
377 |
|
* |
378 |
|
* Id is checked for null in cdrInput that then returns |
379 |
|
* null instead of object. |
380 |
|
* |
381 |
* @param c a stream to read from. |
* @param c a stream to read from. |
382 |
* @throws IOException if the stream throws it. |
* @throws IOException if the stream throws it. |
383 |
*/ |
*/ |
388 |
|
|
389 |
int n_profiles = c.read_long(); |
int n_profiles = c.read_long(); |
390 |
|
|
391 |
|
if (n_profiles == 0) |
392 |
|
{ |
393 |
|
Id = null; |
394 |
|
Internet = null; |
395 |
|
return; |
396 |
|
} |
397 |
|
|
398 |
for (int i = 0; i < n_profiles; i++) |
for (int i = 0; i < n_profiles; i++) |
399 |
{ |
{ |
400 |
int tag = c.read_long(); |
int tag = c.read_long(); |
449 |
} |
} |
450 |
|
|
451 |
/** |
/** |
452 |
|
* Write a null value to the CDR output stream. |
453 |
|
* |
454 |
|
* The null value is written as defined in OMG specification |
455 |
|
* (zero length string, followed by an empty set of profiles). |
456 |
|
*/ |
457 |
|
public static void write_null(cdrOutput out) |
458 |
|
{ |
459 |
|
// Empty Id string. |
460 |
|
out.write_string(""); |
461 |
|
|
462 |
|
// Empty set of profiles. |
463 |
|
out.write_long(0); |
464 |
|
} |
465 |
|
|
466 |
|
/** |
467 |
* Write this IOR record to the provided CDR stream. The procedure |
* Write this IOR record to the provided CDR stream. The procedure |
468 |
* writed data in Big Endian, but does NOT add any endian marker |
* writed data in Big Endian, but does NOT add any endian marker |
469 |
* to the beginning. |
* to the beginning. |