FileType

DiagramRootPackage.FileType property

Gets the file type metadata package.

public DiagramTypePackage FileType { get; }

Property Value

The file type metadata package.

Examples

This code sample shows how to detect the exact type of a loaded diagram and extract some additional file format information.

using (Metadata metadata = new Metadata(Constants.InputVdx))
{
    var root = metadata.GetRootPackage<DiagramRootPackage>();

    Console.WriteLine(root.FileType.FileFormat);
    Console.WriteLine(root.FileType.DiagramFormat);
    Console.WriteLine(root.FileType.MimeType);
    Console.WriteLine(root.FileType.Extension);
}

See Also