CSharp.WriteConstantValue Method
- Namespace
- Kampute.DocToolkit.Languages
- Assembly
- Kampute.DocToolkit.dll
Definition
Writes a constant value formatted according to C# syntax rules to the provided TextWriter.
public virtual void WriteConstantValue(
TextWriter writer,
object value,
IType valueType = null,
MemberDocLinker linker = null)Parameters
writerTextWriter- The TextWriter to which the constant value is written.
valueobject- The value to be formatted as a constant and written.
valueTypeIType optional- The type of the value to be written. If
null, the type is inferred from the value. linkerMemberDocLinker optional- An optional delegate for linking to the documentation of a type or type's member.
Exceptions
- ArgumentNullException
- Thrown when
writerisnull. - ArgumentException
- Thrown when the
valueis not a constant value.
