what is the keyword "transient"?

  • Thread starter Thread starter assaf
  • Start date Start date
A

assaf

hi all

in the visual studio.net help,
i found the following description of
RSAParameters:


RSAParameters.D Field

[C#]
[NonSerialized]
public transient byte[] D;



i could not find any information about the keyword:
"transient".


could someone please enlighten me about "transient"?

assaf
 
assaf,

There is no keyword/statement "transient" in C# (from what I can tell).
The compiler is spitting up errors everywhere when I try and use it.

Can you compile code that uses "transient"? If so, can you provide the
code? The code you gave does not compile (as it shouldn't).
 
indeed very strange. looks like it's a java keyword that C# once might have
considered borrowing. but someone didn't update them out of the docs?

Nicholas Paldino said:
assaf,

There is no keyword/statement "transient" in C# (from what I can tell).
The compiler is spitting up errors everywhere when I try and use it.

Can you compile code that uses "transient"? If so, can you provide the
code? The code you gave does not compile (as it shouldn't).


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

assaf said:
hi all

in the visual studio.net help,
i found the following description of
RSAParameters:


RSAParameters.D Field

[C#]
[NonSerialized]
public transient byte[] D;



i could not find any information about the keyword:
"transient".


could someone please enlighten me about "transient"?

assaf
 
Daniel Jin said:
looks like it's a java keyword that C# once might have considered
borrowing.
That is correct. It is used in java to specify that a specific member in an
otherwise
serializable class should not be serialized.
--
Regards,
Dennis JD Myrén
Oslo Kodebureau
Daniel Jin said:
indeed very strange. looks like it's a java keyword that C# once might
have
considered borrowing. but someone didn't update them out of the docs?

Nicholas Paldino said:
assaf,

There is no keyword/statement "transient" in C# (from what I can
tell).
The compiler is spitting up errors everywhere when I try and use it.

Can you compile code that uses "transient"? If so, can you provide
the
code? The code you gave does not compile (as it shouldn't).


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

assaf said:
hi all

in the visual studio.net help,
i found the following description of
RSAParameters:


RSAParameters.D Field

[C#]
[NonSerialized]
public transient byte[] D;



i could not find any information about the keyword:
"transient".


could someone please enlighten me about "transient"?

assaf
 
assaf said:
[NonSerialized]
public transient byte[] D;

Apparently, [NotSerialized] is the C# equivalent of 'transient' in
Java, so 'transient' should not be present in that C# declaration.

P.
 
thank u all.


Dennis Myrén said:
Daniel Jin said:
looks like it's a java keyword that C# once might have considered
borrowing.
That is correct. It is used in java to specify that a specific member in an
otherwise
serializable class should not be serialized.
--
Regards,
Dennis JD Myrén
Oslo Kodebureau
Daniel Jin said:
indeed very strange. looks like it's a java keyword that C# once might
have
considered borrowing. but someone didn't update them out of the docs?

Nicholas Paldino said:
assaf,

There is no keyword/statement "transient" in C# (from what I can
tell).
The compiler is spitting up errors everywhere when I try and use it.

Can you compile code that uses "transient"? If so, can you provide
the
code? The code you gave does not compile (as it shouldn't).


--
- Nicholas Paldino [.NET/C# MVP]
- (e-mail address removed)

hi all

in the visual studio.net help,
i found the following description of
RSAParameters:


RSAParameters.D Field

[C#]
[NonSerialized]
public transient byte[] D;



i could not find any information about the keyword:
"transient".


could someone please enlighten me about "transient"?

assaf
 
Back
Top