added Revit 2022 SDK minus except *rvt and *rfa

This commit is contained in:
Jeremy Tammik
2021-04-20 11:36:21 +02:00
parent 1133a82dc5
commit 7e327986e8
3034 changed files with 1245318 additions and 0 deletions
@@ -0,0 +1,71 @@
//
// (C) Copyright 2003-2019 by Autodesk, Inc.
//
// Permission to use, copy, modify, and distribute this software in
// object code form for any purpose and without fee is hereby granted,
// provided that the above copyright notice appears in all copies and
// that both that copyright notice and the limited warranty and
// restricted rights notice below appear in all supporting
// documentation.
//
// AUTODESK PROVIDES THIS PROGRAM "AS IS" AND WITH ALL FAULTS.
// AUTODESK SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. AUTODESK, INC.
// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
// UNINTERRUPTED OR ERROR FREE.
//
// Use, duplication, or disclosure by the U.S. Government is subject to
// restrictions set forth in FAR 52.227-19 (Commercial Computer
// Software - Restricted Rights) and DFAR 252.227-7013(c)(1)(ii)
// (Rights in Technical Data and Computer Software), as applicable.
//
using System;
using Autodesk.Revit.DB;
using Autodesk.Revit.UI;
namespace ExtensibleStorageManager
{
public class Application : IExternalApplication
{
/// <summary>
/// There is no cleanup needed in this application -- default implementation
/// </summary>
public Result OnShutdown(UIControlledApplication application)
{
return Result.Succeeded;
}
/// <summary>
/// Add a button to the Ribbon and attach it to the IExternalCommand defined in Command.cs
/// </summary>
public Result OnStartup(UIControlledApplication application)
{
RibbonPanel rp = application.CreateRibbonPanel("Extensible Storage Manager");
string currentAssembly = System.Reflection.Assembly.GetAssembly(this.GetType()).Location;
PushButton pb = rp.AddItem(new PushButtonData("Extensible Storage Manager", "Extensible Storage Manager", currentAssembly, "ExtensibleStorageManager.Command")) as PushButton;
return Result.Succeeded;
}
/// <summary>
/// The Last Schema Guid value used in the UICommand dialog is stored here for future retrieval
/// after the dialog is closed.
/// </summary>
public static string LastGuid
{
get { return m_lastGuid; }
set { m_lastGuid = value; }
}
private static string m_lastGuid;
}
}
@@ -0,0 +1,57 @@
//
// (C) Copyright 2003-2019 by Autodesk, Inc.
//
// Permission to use, copy, modify, and distribute this software in
// object code form for any purpose and without fee is hereby granted,
// provided that the above copyright notice appears in all copies and
// that both that copyright notice and the limited warranty and
// restricted rights notice below appear in all supporting
// documentation.
//
// AUTODESK PROVIDES THIS PROGRAM "AS IS" AND WITH ALL FAULTS.
// AUTODESK SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. AUTODESK, INC.
// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
// UNINTERRUPTED OR ERROR FREE.
//
// Use, duplication, or disclosure by the U.S. Government is subject to
// restrictions set forth in FAR 52.227-19 (Commercial Computer
// Software - Restricted Rights) and DFAR 252.227-7013(c)(1)(ii)
// (Rights in Technical Data and Computer Software), as applicable.
//
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Autodesk.Revit.DB;
using Autodesk.Revit.UI;
using Autodesk.Revit.DB.ExtensibleStorage;
using System.Reflection;
namespace ExtensibleStorageManager
{
[Autodesk.Revit.Attributes.Transaction(Autodesk.Revit.Attributes.TransactionMode.Manual)]
[Autodesk.Revit.Attributes.Journaling(Autodesk.Revit.Attributes.JournalingMode.NoCommandData)]
public class Command : IExternalCommand
{
public Result Execute(ExternalCommandData commandData, ref string message, ElementSet elements)
{
UICommand dialog = new UICommand(commandData.Application.ActiveUIDocument.Document, commandData.Application.ActiveAddInId.GetGUID().ToString());
dialog.ShowDialog();
return Result.Succeeded;
}
}
}
@@ -0,0 +1,21 @@
<?xml version="1.0" encoding="utf-8"?>
<RevitAddIns>
<AddIn Type="Application">
<Name>ExtensibleStorageManager</Name>
<Assembly>ExtensibleStorageManager.dll</Assembly>
<AddInId>DEC00020-2010-4338-8de4-ADDCADCADCAD</AddInId>
<FullClassName>ExtensibleStorageManager.Application</FullClassName>
<VendorId>adsk</VendorId>
<VendorDescription>Autodesk, www.autodesk.com</VendorDescription>
</AddIn>
<AddIn Type="Command">
<Assembly>ExtensibleStorageManager.dll</Assembly>
<ClientId>0183228C-5DFC-4db2-A191-A3BB2A83EB46</ClientId>
<FullClassName>ExtensibleStorageManager.Command</FullClassName>
<Text>Extensible Storage Manager</Text>
<Description>Extensible Storage Manager</Description>
<VisibilityMode>AlwaysVisible</VisibilityMode>
<VendorId>ADSK</VendorId>
<VendorDescription>Autodesk, www.autodesk.com</VendorDescription>
</AddIn>
</RevitAddIns>
@@ -0,0 +1,134 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>9.0.30729</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{D80CD23C-5D40-4BE6-8940-5CE791DEF719}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>ExtensibleStorageManager</RootNamespace>
<AssemblyName>ExtensibleStorageManager</AssemblyName>
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<FileUpgradeFlags>
</FileUpgradeFlags>
<OldToolsVersion>3.5</OldToolsVersion>
<UpgradeBackupLocation />
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\x64\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<DebugType>full</DebugType>
<PlatformTarget>x64</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'">
<OutputPath>bin\x64\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<DebugType>pdbonly</DebugType>
<PlatformTarget>x64</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>AllRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup>
<RunPostBuildEvent>OnOutputUpdated</RunPostBuildEvent>
</PropertyGroup>
<ItemGroup>
<Reference Include="Microsoft.VisualBasic" />
<Reference Include="PresentationCore">
<RequiredTargetFramework>3.0</RequiredTargetFramework>
</Reference>
<Reference Include="PresentationFramework">
<RequiredTargetFramework>3.0</RequiredTargetFramework>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Xaml" />
<Reference Include="System.Xml.Linq">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data.DataSetExtensions">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
<Reference Include="UIAutomationProvider">
<RequiredTargetFramework>3.0</RequiredTargetFramework>
</Reference>
<Reference Include="WindowsBase">
<RequiredTargetFramework>3.0</RequiredTargetFramework>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="Application\Application.cs" />
<Compile Include="User\StorageCommand.cs" />
<Compile Include="Application\Command.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="User\UICommand.xaml.cs">
<DependentUpon>UICommand.xaml</DependentUpon>
</Compile>
<Compile Include="User\UIData.xaml.cs">
<DependentUpon>UIData.xaml</DependentUpon>
</Compile>
</ItemGroup>
<ItemGroup>
<Page Include="User\UICommand.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
<Page Include="User\UIData.xaml">
<SubType>Designer</SubType>
<Generator>MSBuild:Compile</Generator>
</Page>
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\..\SchemaWrapperTools\CS\SchemaWrapperTools.csproj">
<Project>{D5227927-E688-4996-BEEE-7DCA91A7365B}</Project>
<Name>SchemaWrapperTools</Name>
</ProjectReference>
</ItemGroup>
<Import Project="$(SolutionDir)VSProps\SDKSamples.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
<PropertyGroup>
<ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>None</ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>
</PropertyGroup>
<PropertyGroup>
<PostBuildEvent>set FILEFORSAMPLEREG="$(SolutionDir)..\..\..\..\Regression\API\SDKSamples\UpdateSampleDllForRegression.pl"
if exist %25FILEFORSAMPLEREG%25 perl %25FILEFORSAMPLEREG%25 $(ProjectExt) "$(ProjectPath)" "$(TargetPath)" "$(SolutionDir)"</PostBuildEvent>
</PropertyGroup>
</Project>
@@ -0,0 +1,26 @@
Microsoft Visual Studio Solution File, Format Version 11.00
# Visual Studio 2010
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ExtensibleStorageManager", "ExtensibleStorageManager.csproj", "{D80CD23C-5D40-4BE6-8940-5CE791DEF719}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "SchemaWrapperTools", "..\..\SchemaWrapperTools\CS\SchemaWrapperTools.csproj", "{D5227927-E688-4996-BEEE-7DCA91A7365B}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{D80CD23C-5D40-4BE6-8940-5CE791DEF719}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D80CD23C-5D40-4BE6-8940-5CE791DEF719}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D80CD23C-5D40-4BE6-8940-5CE791DEF719}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D80CD23C-5D40-4BE6-8940-5CE791DEF719}.Release|Any CPU.Build.0 = Release|Any CPU
{D5227927-E688-4996-BEEE-7DCA91A7365B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D5227927-E688-4996-BEEE-7DCA91A7365B}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D5227927-E688-4996-BEEE-7DCA91A7365B}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D5227927-E688-4996-BEEE-7DCA91A7365B}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
EndGlobalSection
EndGlobal
@@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("ExtensibleStorageManager")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("ExtensibleStorageManager")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2010")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("ab0805de-5760-4943-bd66-9456d63d178c")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
@@ -0,0 +1,321 @@
{\rtf1\adeflang1025\ansi\ansicpg1252\uc1\adeff0\deff0\stshfdbch31505\stshfloch31506\stshfhich31506\stshfbi0\deflang1033\deflangfe2052\themelang1033\themelangfe0\themelangcs0{\fonttbl{\f0\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f1\fbidi \fswiss\fcharset0\fprq2{\*\panose 020b0604020202020204}Arial;}
{\f2\fbidi \fmodern\fcharset0\fprq1{\*\panose 02070309020205020404}Courier New;}{\f3\fbidi \froman\fcharset2\fprq2{\*\panose 05050102010706020507}Symbol;}{\f10\fbidi \fnil\fcharset2\fprq2{\*\panose 05000000000000000000}Wingdings;}
{\f34\fbidi \froman\fcharset0\fprq2{\*\panose 02040503050406030204}Cambria Math;}{\flomajor\f31500\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}
{\fdbmajor\f31501\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\fhimajor\f31502\fbidi \froman\fcharset0\fprq2{\*\panose 02040503050406030204}Cambria;}
{\fbimajor\f31503\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\flominor\f31504\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}
{\fdbminor\f31505\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\fhiminor\f31506\fbidi \fswiss\fcharset0\fprq2{\*\panose 020f0502020204030204}Calibri;}
{\fbiminor\f31507\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f39\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\f40\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}
{\f42\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\f43\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\f44\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f45\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}
{\f46\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\f47\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\f49\fbidi \fswiss\fcharset238\fprq2 Arial CE;}{\f50\fbidi \fswiss\fcharset204\fprq2 Arial Cyr;}
{\f52\fbidi \fswiss\fcharset161\fprq2 Arial Greek;}{\f53\fbidi \fswiss\fcharset162\fprq2 Arial Tur;}{\f54\fbidi \fswiss\fcharset177\fprq2 Arial (Hebrew);}{\f55\fbidi \fswiss\fcharset178\fprq2 Arial (Arabic);}
{\f56\fbidi \fswiss\fcharset186\fprq2 Arial Baltic;}{\f57\fbidi \fswiss\fcharset163\fprq2 Arial (Vietnamese);}{\f59\fbidi \fmodern\fcharset238\fprq1 Courier New CE;}{\f60\fbidi \fmodern\fcharset204\fprq1 Courier New Cyr;}
{\f62\fbidi \fmodern\fcharset161\fprq1 Courier New Greek;}{\f63\fbidi \fmodern\fcharset162\fprq1 Courier New Tur;}{\f64\fbidi \fmodern\fcharset177\fprq1 Courier New (Hebrew);}{\f65\fbidi \fmodern\fcharset178\fprq1 Courier New (Arabic);}
{\f66\fbidi \fmodern\fcharset186\fprq1 Courier New Baltic;}{\f67\fbidi \fmodern\fcharset163\fprq1 Courier New (Vietnamese);}{\f379\fbidi \froman\fcharset238\fprq2 Cambria Math CE;}{\f380\fbidi \froman\fcharset204\fprq2 Cambria Math Cyr;}
{\f382\fbidi \froman\fcharset161\fprq2 Cambria Math Greek;}{\f383\fbidi \froman\fcharset162\fprq2 Cambria Math Tur;}{\f386\fbidi \froman\fcharset186\fprq2 Cambria Math Baltic;}{\f387\fbidi \froman\fcharset163\fprq2 Cambria Math (Vietnamese);}
{\flomajor\f31508\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\flomajor\f31509\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\flomajor\f31511\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}
{\flomajor\f31512\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\flomajor\f31513\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\flomajor\f31514\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}
{\flomajor\f31515\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\flomajor\f31516\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\fdbmajor\f31518\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}
{\fdbmajor\f31519\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\fdbmajor\f31521\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\fdbmajor\f31522\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}
{\fdbmajor\f31523\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\fdbmajor\f31524\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\fdbmajor\f31525\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}
{\fdbmajor\f31526\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\fhimajor\f31528\fbidi \froman\fcharset238\fprq2 Cambria CE;}{\fhimajor\f31529\fbidi \froman\fcharset204\fprq2 Cambria Cyr;}
{\fhimajor\f31531\fbidi \froman\fcharset161\fprq2 Cambria Greek;}{\fhimajor\f31532\fbidi \froman\fcharset162\fprq2 Cambria Tur;}{\fhimajor\f31535\fbidi \froman\fcharset186\fprq2 Cambria Baltic;}
{\fhimajor\f31536\fbidi \froman\fcharset163\fprq2 Cambria (Vietnamese);}{\fbimajor\f31538\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\fbimajor\f31539\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}
{\fbimajor\f31541\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\fbimajor\f31542\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\fbimajor\f31543\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}
{\fbimajor\f31544\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\fbimajor\f31545\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\fbimajor\f31546\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}
{\flominor\f31548\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\flominor\f31549\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\flominor\f31551\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}
{\flominor\f31552\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\flominor\f31553\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\flominor\f31554\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}
{\flominor\f31555\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\flominor\f31556\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\fdbminor\f31558\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}
{\fdbminor\f31559\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\fdbminor\f31561\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\fdbminor\f31562\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}
{\fdbminor\f31563\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\fdbminor\f31564\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\fdbminor\f31565\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}
{\fdbminor\f31566\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\fhiminor\f31568\fbidi \fswiss\fcharset238\fprq2 Calibri CE;}{\fhiminor\f31569\fbidi \fswiss\fcharset204\fprq2 Calibri Cyr;}
{\fhiminor\f31571\fbidi \fswiss\fcharset161\fprq2 Calibri Greek;}{\fhiminor\f31572\fbidi \fswiss\fcharset162\fprq2 Calibri Tur;}{\fhiminor\f31575\fbidi \fswiss\fcharset186\fprq2 Calibri Baltic;}
{\fhiminor\f31576\fbidi \fswiss\fcharset163\fprq2 Calibri (Vietnamese);}{\fbiminor\f31578\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\fbiminor\f31579\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}
{\fbiminor\f31581\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\fbiminor\f31582\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\fbiminor\f31583\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}
{\fbiminor\f31584\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\fbiminor\f31585\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\fbiminor\f31586\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}}
{\colortbl;\red0\green0\blue0;\red0\green0\blue255;\red0\green255\blue255;\red0\green255\blue0;\red255\green0\blue255;\red255\green0\blue0;\red255\green255\blue0;\red255\green255\blue255;\red0\green0\blue128;\red0\green128\blue128;\red0\green128\blue0;
\red128\green0\blue128;\red128\green0\blue0;\red128\green128\blue0;\red128\green128\blue128;\red192\green192\blue192;}{\*\defchp \fs22\loch\af31506\hich\af31506\dbch\af31505 }{\*\defpap \ql \li0\ri0\sa200\sl276\slmult1
\widctlpar\wrapdefault\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 }\noqfpromote {\stylesheet{\ql \li0\ri0\sa200\sl276\slmult1\widctlpar\wrapdefault\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \rtlch\fcs1 \af0\afs22\alang1025 \ltrch\fcs0
\fs22\lang1033\langfe1033\loch\f31506\hich\af31506\dbch\af31505\cgrid\langnp1033\langfenp1033 \snext0 \sqformat \spriority0 Normal;}{\*\cs10 \additive \ssemihidden \sunhideused \spriority1 Default Paragraph Font;}{\*
\ts11\tsrowd\trftsWidthB3\trpaddl108\trpaddr108\trpaddfl3\trpaddft3\trpaddfb3\trpaddfr3\trcbpat1\trcfpat1\tblind0\tblindtype3\tscellwidthfts0\tsvertalt\tsbrdrt\tsbrdrl\tsbrdrb\tsbrdrr\tsbrdrdgl\tsbrdrdgr\tsbrdrh\tsbrdrv \ql \li0\ri0\sa200\sl276\slmult1
\widctlpar\wrapdefault\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \rtlch\fcs1 \af0\afs22\alang1025 \ltrch\fcs0 \fs22\lang1033\langfe2052\loch\f31506\hich\af31506\dbch\af31505\cgrid\langnp1033\langfenp2052
\snext11 \ssemihidden \sunhideused \sqformat Normal Table;}}{\*\listtable{\list\listtemplateid-889555842\listhybrid{\listlevel\levelnfc0\levelnfcn0\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace0\levelindent0{\leveltext\leveltemplateid2035172364
\'02\'00);}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0 \fbias0\hres0\chhres0 \fi-360\li1200\lin1200 }{\listlevel\levelnfc4\levelnfcn4\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext
\leveltemplateid67698713\'02\'01.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0 \hres0\chhres0 \fi-360\li1920\lin1920 }{\listlevel\levelnfc2\levelnfcn2\leveljc2\leveljcn2\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext
\leveltemplateid67698715\'02\'02.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0 \hres0\chhres0 \fi-180\li2640\lin2640 }{\listlevel\levelnfc0\levelnfcn0\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext
\leveltemplateid67698703\'02\'03.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0 \hres0\chhres0 \fi-360\li3360\lin3360 }{\listlevel\levelnfc4\levelnfcn4\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext
\leveltemplateid67698713\'02\'04.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0 \hres0\chhres0 \fi-360\li4080\lin4080 }{\listlevel\levelnfc2\levelnfcn2\leveljc2\leveljcn2\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext
\leveltemplateid67698715\'02\'05.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0 \hres0\chhres0 \fi-180\li4800\lin4800 }{\listlevel\levelnfc0\levelnfcn0\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext
\leveltemplateid67698703\'02\'06.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0 \hres0\chhres0 \fi-360\li5520\lin5520 }{\listlevel\levelnfc4\levelnfcn4\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext
\leveltemplateid67698713\'02\'07.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0 \hres0\chhres0 \fi-360\li6240\lin6240 }{\listlevel\levelnfc2\levelnfcn2\leveljc2\leveljcn2\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext
\leveltemplateid67698715\'02\'08.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0 \hres0\chhres0 \fi-180\li6960\lin6960 }{\listname ;}\listid370811281}{\list\listtemplateid-1850317920\listhybrid{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0
\levelfollow0\levelstartat1\levelspace360\levelindent0{\leveltext\leveltemplateid67698689\'01\u-3913 ?;}{\levelnumbers;}\f3\fbias0\hres0\chhres0 \fi-360\li720\lin720 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1
\levelspace360\levelindent0{\leveltext\leveltemplateid67698691\'01o;}{\levelnumbers;}\f2\fbias0\hres0\chhres0 \fi-360\li1440\lin1440 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace360\levelindent0{\leveltext
\leveltemplateid67698693\'01\u-3929 ?;}{\levelnumbers;}\f10\fbias0\hres0\chhres0 \fi-360\li2160\lin2160 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0{\leveltext
\leveltemplateid67698689\'01\u-3913 ?;}{\levelnumbers;}\f3\fbias0\hres0\chhres0 \fi-360\li2880\lin2880 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0{\leveltext
\leveltemplateid67698691\'01o;}{\levelnumbers;}\f2\fbias0\hres0\chhres0 \fi-360\li3600\lin3600 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0{\leveltext\leveltemplateid67698693
\'01\u-3929 ?;}{\levelnumbers;}\f10\fbias0\hres0\chhres0 \fi-360\li4320\lin4320 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0{\leveltext\leveltemplateid67698689
\'01\u-3913 ?;}{\levelnumbers;}\f3\fbias0\hres0\chhres0 \fi-360\li5040\lin5040 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0{\leveltext\leveltemplateid67698691
\'01o;}{\levelnumbers;}\f2\fbias0\hres0\chhres0 \fi-360\li5760\lin5760 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0{\leveltext\leveltemplateid67698693
\'01\u-3929 ?;}{\levelnumbers;}\f10\fbias0\hres0\chhres0 \fi-360\li6480\lin6480 }{\listname ;}\listid499009686}}{\*\listoverridetable{\listoverride\listid499009686\listoverridecount0\ls1}{\listoverride\listid370811281\listoverridecount0\ls2}}
{\*\rsidtbl \rsid141089\rsid223742\rsid727263\rsid1384628\rsid1452415\rsid1643735\rsid2504070\rsid2694459\rsid2706698\rsid3675435\rsid5207864\rsid5965259\rsid6188422\rsid7343557\rsid7606740\rsid8523953\rsid9256058\rsid9325637\rsid9401674\rsid10321559
\rsid10702366\rsid11015752\rsid12857485\rsid13661538\rsid14306083\rsid14842436\rsid15232447\rsid15949907\rsid16518296}{\mmathPr\mmathFont34\mbrkBin0\mbrkBinSub0\msmallFrac0\mdispDef1\mlMargin0\mrMargin0\mdefJc1\mwrapIndent1440\mintLim0\mnaryLim1}{\info
{\author Steven Mycynek}{\operator Autodesk, Inc.}{\creatim\yr2010\mo12\dy20\hr12\min6}{\revtim\yr2011\mo2\dy17\hr14\min45}{\version20}{\edmins71}{\nofpages2}{\nofwords648}{\nofchars3946}{\*\company Autodesk, Inc.}{\nofcharsws4585}{\vern32771}}
{\*\xmlnstbl {\xmlns1 http://schemas.microsoft.com/office/word/2003/wordml}}\paperw12240\paperh15840\margl1440\margr1440\margt1440\margb1440\gutter0\ltrsect
\deftab420\widowctrl\ftnbj\aenddoc\trackmoves0\trackformatting1\donotembedsysfont0\relyonvml0\donotembedlingdata1\grfdocevents0\validatexml0\showplaceholdtext0\ignoremixedcontent0\saveinvalidxml0\showxmlerrors0\horzdoc\dghspace120\dgvspace120
\dghorigin1701\dgvorigin1984\dghshow0\dgvshow3\jcompress\ksulang1041\viewkind1\viewscale100\rsidroot2706698 {\*\fchars !),.:\'3b?D]\'7d}{\*\lchars ([\'7b}\fet0{\*\wgrffmtfilter 2450}\ilfomacatclnup0\ltrpar \sectd \ltrsect\linex0\sectdefaultcl\sftnbj
{\*\pnseclvl1\pnucrm\pnstart1\pnindent720\pnhang {\pntxta .}}{\*\pnseclvl2\pnucltr\pnstart1\pnindent720\pnhang {\pntxta .}}{\*\pnseclvl3\pndec\pnstart1\pnindent720\pnhang {\pntxta .}}{\*\pnseclvl4\pnlcltr\pnstart1\pnindent720\pnhang {\pntxta )}}
{\*\pnseclvl5\pndec\pnstart1\pnindent720\pnhang {\pntxtb (}{\pntxta )}}{\*\pnseclvl6\pnlcltr\pnstart1\pnindent720\pnhang {\pntxtb (}{\pntxta )}}{\*\pnseclvl7\pnlcrm\pnstart1\pnindent720\pnhang {\pntxtb (}{\pntxta )}}{\*\pnseclvl8
\pnlcltr\pnstart1\pnindent720\pnhang {\pntxtb (}{\pntxta )}}{\*\pnseclvl9\pnlcrm\pnstart1\pnindent720\pnhang {\pntxtb (}{\pntxta )}}\pard\plain \ltrpar\ql \li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0 \rtlch\fcs1 \af0\afs22\alang1025
\ltrch\fcs0 \fs22\lang1033\langfe1033\loch\af31506\hich\af31506\dbch\af31505\cgrid\langnp1033\langfenp1033 {\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Application:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 ExtensibleStorageManager}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \line }{\rtlch\fcs1
\ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Revit Platform:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 All\line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0
\b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Revit Version:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 201}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid6188422
\hich\af1\dbch\af31505\loch\f1 2}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 .0\line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 First Released For:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid6188422 \hich\af1\dbch\af31505\loch\f1 2012.0}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Programming Language:}{
\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid6188422 \hich\af1\dbch\af31505\loch\f1 C#}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \line }{
\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Skill Level:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid9325637 \hich\af1\dbch\af31505\loch\f1 Advanced}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Category:}{\rtlch\fcs1
\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid6188422 \hich\af1\dbch\af31505\loch\f1 Elements}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \line }{
\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Type:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid223742
\hich\af1\dbch\af31505\loch\f1 ExternalCommand, ExternalApplication}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \line \line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Subject:}{
\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1384628 \hich\af1\dbch\af31505\loch\f1
Create, read, update, and delete third party extensible storage in Revit Elements.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Summary:}{
\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1643735 \hich\af1\dbch\af31505\loch\f1 \line This application demonstrates the }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 ExtensibleStorage}{\rtlch\fcs1
\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid14842436 \hich\af1\dbch\af31505\loch\f1 class}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 es}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid14842436
\hich\af1\dbch\af31505\loch\f1 and }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1643735 \hich\af1\dbch\af31505\loch\f1 r\hich\af1\dbch\af31505\loch\f1
elated APIs by creating a wrapper class and control dialog that creates schemas, serializes and deserializes them to XML, and extracts and displays all data in Entities of those Schemas. This is an advanced sample. If you are not familiar with Extensibl
\hich\af1\dbch\af31505\loch\f1 e\hich\af1\dbch\af31505\loch\f1 Stora}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2504070 \hich\af1\dbch\af31505\loch\f1 ge, first look at the}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1643735
\hich\af1\dbch\af31505\loch\f1 \hich\f1 \'93\loch\f1 \hich\f1 DynamicModelUpdate\'94}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2504070 \hich\af1\dbch\af31505\loch\f1 sample.}{\rtlch\fcs1 \ai\af0\afs20 \ltrch\fcs0 \i\f0\fs20\insrsid727263
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263
\par }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Classes:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1 \af0\afs20 \ltrch\fcs0
\f0\fs20\insrsid727263
\par }\pard \ltrpar\ql \fi360\li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Autodesk.Revit.DB.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\lang1024\langfe1024\noproof\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 ExtensibleStorage.Schema}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 Autodesk.Revit.DB.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\lang1024\langfe1024\noproof\insrsid1384628 \hich\af1\dbch\af31505\loch\f1
ExtensibleStorage.SchemaBuilder}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\lang1024\langfe1024\noproof\insrsid727263
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 Autodesk.Revit.DB.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\lang1024\langfe1024\noproof\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 ExtensibleStorage.Field
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 Autodesk.Revit.DB.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\lang1024\langfe1024\noproof\insrsid1384628 \hich\af1\dbch\af31505\loch\f1
ExtensibleStorage.FieldBuilder
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 Autodesk.Revit.DB.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\lang1024\langfe1024\noproof\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 ExtensibleStorage.Entity}
{\rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f0\fs20\insrsid1384628
\par }\pard \ltrpar\ql \fi360\li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0\pararsid1384628 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 Autodesk.Revit.DB.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\lang1024\langfe1024\noproof\insrsid1384628 \hich\af1\dbch\af31505\loch\f1 Element
\par }\pard \ltrpar\ql \li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid727263
\par }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Project Files:}{\rtlch\fcs1 \ai\af1\afs20 \ltrch\fcs0 \i\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1
\af0\afs20 \ltrch\fcs0 \f0\fs20\cf2\insrsid6188422\charrsid14306083
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid9401674
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid2694459\charrsid2694459 \hich\af1\dbch\af31505\loch\f1 SchemaWrapper}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid2694459 \hich\af1\dbch\af31505\loch\f1 Tools}{\rtlch\fcs1 \af1\afs20
\ltrch\fcs0 \b\f1\fs20\insrsid2694459\charrsid2694459
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459 \tab \hich\af1\dbch\af31505\loch\f1 SchemaWrapper.cs
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid8523953 \tab \tab \hich\af1\dbch\af31505\loch\f1 Contains a SchemaWrapper class that contains a SchemaDataWrapper object
\par \tab \tab \hich\af1\dbch\af31505\loch\f1 and high-level operations for creating, saving, and reading Schemas
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459 \tab \hich\af1\dbch\af31505\loch\f1 SchemaDataWrapper.cs
\par }\pard \ltrpar\ql \li840\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin840\itap0\pararsid8523953 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid8523953 \hich\af1\dbch\af31505\loch\f1
Contains a SchemaDataWrapper class that contains a collection of FieldData objects and top-level schema information.
\par }\pard \ltrpar\ql \li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459 \tab \hich\af1\dbch\af31505\loch\f1 FieldData.cs
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid8523953 \tab \tab \hich\af1\dbch\af31505\loch\f1 Contains a FieldData class that w\hich\af1\dbch\af31505\loch\f1 raps the data in a Schema field.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid2694459
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid2694459\charrsid2694459 \hich\af1\dbch\af31505\loch\f1 ExtensibleStorageManager
\par }\pard \ltrpar\ql \fi420\li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0\pararsid2694459 {\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459\charrsid2694459 \hich\af1\dbch\af31505\loch\f1 Application.cs}{\rtlch\fcs1 \ab\af1\afs20
\ltrch\fcs0 \f1\fs20\insrsid8523953 \hich\af1\dbch\af31505\loch\f1 \hich\f1 \endash \loch\f1 contains the main IExternalApplication that creates a command Ribbon button}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459\charrsid2694459
\par \hich\af1\dbch\af31505\loch\f1 Command.cs}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid8523953 \hich\af1\dbch\af31505\loch\f1 -- contains the main IExternalCommand to launch the control dialog UICommand}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid2694459\charrsid2694459
\par \\\hich\af1\dbch\af31505\loch\f1 User\\\hich\af1\dbch\af31505\loch\f1 StorageCommand.cs}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459
\par }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid8523953 \tab \hich\af1\dbch\af31505\loch\f1 Contains the high-level commands for creating and analyzing Schemas and Entities}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid8523953\charrsid2694459
\par }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459\charrsid2694459 \\\hich\af1\dbch\af31505\loch\f1 User\\UICommand.xaml}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459
\par }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid8523953 \tab \hich\af1\dbch\af31505\loch\f1 The main dialog layout}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid8523953\charrsid2694459
\par }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459\charrsid2694459 \\\hich\af1\dbch\af31505\loch\f1 User\\UICommand.xaml.cs}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459
\par }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid8523953 \tab \hich\af1\dbch\af31505\loch\f1 The main dialog implementation \hich\f1 \endash \loch\f1 uses the commands in StorageCommand.cs}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid8523953\charrsid2694459
\par }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459\charrsid2694459 \\\hich\af1\dbch\af31505\loch\f1 User\\UIData.x\hich\af1\dbch\af31505\loch\f1 aml}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459
\par }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid8523953 \tab \hich\af1\dbch\af31505\loch\f1 The data window layout}{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid8523953\charrsid2694459
\par }\pard \ltrpar\ql \li420\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin420\itap0\pararsid2694459 {\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid2694459\charrsid2694459 \\\hich\af1\dbch\af31505\loch\f1 User\\UIData.xaml.cs}{\rtlch\fcs1 \ab\af1\afs20
\ltrch\fcs0 \f1\fs20\insrsid8523953
\par }\pard \ltrpar\ql \fi420\li420\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin420\itap0\pararsid8523953 {\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid5965259 \hich\af1\dbch\af31505\loch\f1 The data window implementation
\par \page }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid5965259
\par }\pard \ltrpar\ql \li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid5965259\charrsid5965259 \hich\af1\dbch\af31505\loch\f1 Description:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\b\f1\fs20\insrsid10321559\charrsid5965259
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid10702366 \tab \hich\af1\dbch\af31505\loch\f1 The ExtensibleStorage Manager application contains two projects
\par \tab \tab
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f3\fs20\lang1033\langfe1033\langfenp1033\insrsid10702366 \loch\af3\dbch\af31505\hich\f3 \'b7\tab}}\pard \ltrpar
\ql \fi-360\li720\ri0\nowidctlpar\wrapdefault\faauto\ls1\rin0\lin720\itap0\pararsid10702366 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid10702366 \hich\af1\dbch\af31505\loch\f1 SchemaWrapper}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid2694459 \hich\af1\dbch\af31505\loch\f1 Tools}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid10702366
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f2\fs20\lang1033\langfe1033\langfenp1033\insrsid10702366 \hich\af2\dbch\af31505\loch\f2 o\tab}}\pard \ltrpar
\ql \fi-360\li1440\ri0\nowidctlpar\wrapdefault\faauto\ls1\ilvl1\rin0\lin1440\itap0\pararsid10702366 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid10702366 \hich\af1\dbch\af31505\loch\f1
A C# library that encapsulates the Autodesk.Revit.DB.ExtensibleStorage}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid1643735 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid10702366
\hich\af1\dbch\af31505\loch\f1 Schema, SchemaBuilder, Field, and FieldBuilder, and provides support to
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f10\fs20\lang1033\langfe1033\langfenp1033\insrsid10702366 \loch\af10\dbch\af31505\hich\f10 \'a7\tab}}\pard \ltrpar
\ql \fi-360\li2160\ri0\nowidctlpar\wrapdefault\faauto\ls1\ilvl2\rin0\lin2160\itap0\pararsid10702366 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid10702366 \hich\af1\dbch\af31505\loch\f1 Serialize schema data to and from disk
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f10\fs20\lang1033\langfe1033\langfenp1033\insrsid10702366 \loch\af10\dbch\af31505\hich\f10 \'a7\tab}\hich\af1\dbch\af31505\loch\f1
Display all data in an Entity that contains data of a particular Schema
\par }\pard \ltrpar\ql \fi420\li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0\pararsid10702366 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid10702366
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f3\fs20\lang1033\langfe1033\langfenp1033\insrsid10702366 \loch\af3\dbch\af31505\hich\f3 \'b7\tab}}\pard \ltrpar
\ql \fi-360\li720\ri0\nowidctlpar\wrapdefault\faauto\ls1\rin0\lin720\itap0\pararsid12857485 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid10702366 \hich\af1\dbch\af31505\loch\f1 ExtensibleSt\hich\af1\dbch\af31505\loch\f1
orageManager, a Revit IExternalCommand and IExternalApplication that launches a WPF dialog that allows you to interact with the SchemaWrapper class}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid9256058 \hich\af1\dbch\af31505\loch\f1
and view data and schemas serialized into elements in a Revit document.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid10702366
\par }\pard \ltrpar\ql \li1440\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin1440\itap0\pararsid10702366 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid10702366
\par }\pard \ltrpar\ql \li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0 {\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid727263 \hich\af1\dbch\af31505\loch\f1 Instructions:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\cf2\insrsid727263
\hich\af1\dbch\af31505\loch\f1
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 1)\tab}}\pard \ltrpar
\ql \fi-360\li1200\ri0\nowidctlpar\wrapdefault\faauto\ls2\rin0\lin1200\itap0\pararsid14306083 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 Build and install}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid13661538 \hich\af1\dbch\af31505\loch\f1 the ExtensibleStorageManager }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 IExternalApplication.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid10321559
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 2)\tab}}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid14306083 \hich\af1\dbch\af31505\loch\f1
Create a new Revit document.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 3)\tab}\hich\af1\dbch\af31505\loch\f1 Sele}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid13661538 \hich\af1\dbch\af31505\loch\f1 ct the ExtensibleStorageManager }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 ribbon button.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 4)\tab}\hich\af1\dbch\af31505\loch\f1 \hich\f1 Click the \'93\loch\f1 \hich\f1 New Id\'94\loch\f1
button in the dialog.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 5)\tab}\hich\af1\dbch\af31505\loch\f1
Give your new schema a name and description, and select read/write perm\hich\af1\dbch\af31505\loch\f1 issions.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 6)\tab}\hich\af1\dbch\af31505\loch\f1 Select one of the }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid1643735 \hich\af1\dbch\af31505\loch\f1 two}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 \hich\f1 \'93\loch\f1 \hich\f1 Create new Schema\'94\loch\f1 \hich\f1 buttons. (Select the first \'93
\loch\f1 \hich\f1 Simple\'94\loch\f1 option for now.)
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 7)\tab}\hich\af1\dbch\af31505\loch\f1
Select a pathname for the schema XML file to export, and click OK.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 8)\tab}\hich\af1\dbch\af31505\loch\f1
Revit will now build a small schema, add data to it, and will display the sc\hich\af1\dbch\af31505\loch\f1 hema and data in a window.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 9)\tab}\hich\af1\dbch\af31505\loch\f1
Close the dialogs, save the Revit document, close it, and reopen it.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 10)\tab}\hich\af1\dbch\af31505\loch\f1 Launch the ExtensibleStorageManager dialog again.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 11)\tab}\hich\af1\dbch\af31505\loch\f1 \hich\f1 Select the \'93\loch\f1 \hich\f1
Create SchemaWrapper from Xml\'94\loch\f1 button.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 12)\tab}\hich\af1\dbch\af31505\loch\f1 Select the xml file you specified in step 7.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 13)\tab}\hich\af1\dbch\af31505\loch\f1
Note that the schema has been re-created from XML and is displayed in a window.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid14306083 \hich\af1\dbch\af31505\loch\f1 14)\tab}\hich\af1\dbch\af31505\loch\f1 \hich\f1 Select the \'93\loch\f1
Look up schema and extract entity}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid13661538 \loch\af1\dbch\af31505\hich\f1 \'94\loch\f1 button. This will query the R}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid14306083
\hich\af1\dbch\af31505\loch\f1 evit document for the data you saved in step 7 and display it in a window.
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid13661538 \hich\af1\dbch\af31505\loch\f1 15)\tab}}\pard \ltrpar
\ql \fi-360\li1200\ri0\nowidctlpar\wrapdefault\faauto\ls2\rin0\lin1200\itap0\pararsid13661538 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid13661538 \hich\af1\dbch\af31505\loch\f1 Select the \loch\af1\dbch\af31505\hich\f1 \'93\loch\f1
Edit Existing Data \hich\f1 \endash \loch\f1 \hich\f1 Simple\'94\loch\f1 button to query and edit the data you set in step 7.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid9325637
\par {\listtext\pard\plain\ltrpar \rtlch\fcs1 \af0\afs20 \ltrch\fcs0 \f1\fs20\lang1033\langfe1033\langfenp1033\insrsid13661538 \hich\af1\dbch\af31505\loch\f1 16)\tab}}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid13661538 \hich\af1\dbch\af31505\loch\f1
\hich\f1 Select \'93\loch\f1 \hich\f1 Create SchemaWrapper from Schema\'94\loch\f1 to create a new SchemaWrapper from the Guid in the}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid15949907 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1 \af1\afs20
\ltrch\fcs0 \f1\fs20\insrsid15232447 \hich\af1\dbch\af31505\loch\f1 Schema ID}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid15949907 \hich\af1\dbch\af31505\loch\f1 t}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid13661538
\hich\af1\dbch\af31505\loch\f1 ext}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid15949907 \hich\af1\dbch\af31505\loch\f1 f}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid13661538 \hich\af1\dbch\af31505\loch\f1
ield. You can use this to analyze or serialize schemas from\hich\af1\dbch\af31505\loch\f1 other documents you did not create.
\par }\pard \ltrpar\ql \li1200\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin1200\itap0\pararsid13661538 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid13661538\charrsid13661538
\par }\pard \ltrpar\ql \li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0\pararsid13661538 {\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid9325637 \hich\af1\dbch\af31505\loch\f1 Note}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid1643735
\hich\af1\dbch\af31505\loch\f1 s}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid9325637\charrsid9325637 \hich\af1\dbch\af31505\loch\f1 :}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid9325637 \line \hich\af1\dbch\af31505\loch\f1
This sample makes very heavy use of generics and reflection to query types, create types, call methods, query generic parameters, and create generic container classes based on types discovered at runtime. }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0
\f1\fs20\insrsid15949907
\par
\par }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid9325637 \hich\af1\dbch\af31505\loch\f1 Thi\hich\af1\dbch\af31505\loch\f1
s use of reflection may be a challenge at first, but it allows the user to xml serialize schemas containing any number of any data types, any supported container type of any supported data type, or any number of different sub-schemas containing any of the
\hich\af1\dbch\af31505\loch\f1 s\hich\af1\dbch\af31505\loch\f1
e types. A recommended approach is to create simple schemas at first with just a few fields and seeing how the SchemaWrapper creates Schema objects and XML from them before moving onto lists of objects, maps of objects, and sub-schemas or lists or maps
\hich\af1\dbch\af31505\loch\f1 \hich\af1\dbch\af31505\loch\f1 of sub-schemas.}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid9325637\charrsid14306083
\par }{\*\themedata 504b030414000600080000002100828abc13fa0000001c020000130000005b436f6e74656e745f54797065735d2e786d6cac91cb6ac3301045f785fe83d0b6d8
72ba28a5d8cea249777d2cd20f18e4b12d6a8f843409c9df77ecb850ba082d74231062ce997b55ae8fe3a00e1893f354e9555e6885647de3a8abf4fbee29bbd7
2a3150038327acf409935ed7d757e5ee14302999a654e99e393c18936c8f23a4dc072479697d1c81e51a3b13c07e4087e6b628ee8cf5c4489cf1c4d075f92a0b
44d7a07a83c82f308ac7b0a0f0fbf90c2480980b58abc733615aa2d210c2e02cb04430076a7ee833dfb6ce62e3ed7e14693e8317d8cd0433bf5c60f53fea2fe7
065bd80facb647e9e25c7fc421fd2ddb526b2e9373fed4bb902e182e97b7b461e6bfad3f010000ffff0300504b030414000600080000002100a5d6a7e7c00000
00360100000b0000005f72656c732f2e72656c73848fcf6ac3300c87ef85bd83d17d51d2c31825762fa590432fa37d00e1287f68221bdb1bebdb4fc7060abb08
84a4eff7a93dfeae8bf9e194e720169aaa06c3e2433fcb68e1763dbf7f82c985a4a725085b787086a37bdbb55fbc50d1a33ccd311ba548b63095120f88d94fbc
52ae4264d1c910d24a45db3462247fa791715fd71f989e19e0364cd3f51652d73760ae8fa8c9ffb3c330cc9e4fc17faf2ce545046e37944c69e462a1a82fe353
bd90a865aad41ed0b5b8f9d6fd010000ffff0300504b0304140006000800000021006b799616830000008a0000001c0000007468656d652f7468656d652f7468
656d654d616e616765722e786d6c0ccc4d0ac3201040e17da17790d93763bb284562b2cbaebbf600439c1a41c7a0d29fdbd7e5e38337cedf14d59b4b0d592c9c
070d8a65cd2e88b7f07c2ca71ba8da481cc52c6ce1c715e6e97818c9b48d13df49c873517d23d59085adb5dd20d6b52bd521ef2cdd5eb9246a3d8b4757e8d3f7
29e245eb2b260a0238fd010000ffff0300504b03041400060008000000210030dd4329a8060000a41b0000160000007468656d652f7468656d652f7468656d65
312e786d6cec594f6fdb3614bf0fd87720746f6327761a07758ad8b19b2d4d1bc46e871e698996d850a240d2497d1bdae38001c3ba618715d86d87615b8116d8
a5fb34d93a6c1dd0afb0475292c5585e9236d88aad3e2412f9e3fbff1e1fa9abd7eec70c1d1221294fda5efd72cd4324f1794093b0eddd1ef62fad79482a9c04
98f184b4bd2991deb58df7dfbb8ad755446282607d22d771db8b944ad79796a40fc3585ee62949606ecc458c15bc8a702910f808e8c66c69b9565b5d8a314d3c
94e018c8de1a8fa94fd05093f43672e23d06af89927ac06762a049136785c10607758d9053d965021d62d6f6804fc08f86e4bef210c352c144dbab999fb7b471
7509af678b985ab0b6b4ae6f7ed9ba6c4170b06c788a705430adf71bad2b5b057d03606a1ed7ebf5babd7a41cf00b0ef83a6569632cd467faddec9699640f671
9e76b7d6ac355c7c89feca9cccad4ea7d36c65b258a206641f1b73f8b5da6a6373d9c11b90c537e7f08dce66b7bbeae00dc8e257e7f0fd2badd5868b37a088d1
e4600ead1ddaef67d40bc898b3ed4af81ac0d76a197c86826828a24bb318f3442d8ab518dfe3a20f000d6458d104a9694ac6d88728eee2782428d60cf03ac1a5
193be4cbb921cd0b495fd054b5bd0f530c1931a3f7eaf9f7af9e3f45c70f9e1d3ff8e9f8e1c3e3073f5a42ceaa6d9c84e5552fbffdeccfc71fa33f9e7ef3f2d1
17d57859c6fffac327bffcfc793510d26726ce8b2f9ffcf6ecc98baf3efdfdbb4715f04d814765f890c644a29be408edf3181433567125272371be15c308d3f2
8acd249438c19a4b05fd9e8a1cf4cd296699771c393ac4b5e01d01e5a30a787d72cf1178108989a2159c77a2d801ee72ce3a5c545a6147f32a99793849c26ae6
6252c6ed637c58c5bb8b13c7bfbd490a75330f4b47f16e441c31f7184e140e494214d273fc80900aedee52ead87597fa824b3e56e82e451d4c2b4d32a423279a
668bb6690c7e9956e90cfe766cb37b077538abd27a8b1cba48c80acc2a841f12e698f13a9e281c57911ce298950d7e03aba84ac8c154f8655c4f2af074481847
bd804859b5e696007d4b4edfc150b12addbecba6b18b148a1e54d1bc81392f23b7f84137c2715a851dd0242a633f900710a218ed715505dfe56e86e877f0034e
16bafb0e258ebb4faf06b769e888340b103d331115bebc4eb813bf83291b63624a0d1475a756c734f9bbc2cd28546ecbe1e20a3794ca175f3fae90fb6d2dd99b
b07b55e5ccf68942bd0877b23c77b908e8db5f9db7f024d9239010f35bd4bbe2fcae387bfff9e2bc289f2fbe24cfaa301468dd8bd846dbb4ddf1c2ae7b4c191b
a8292337a469bc25ec3d411f06f53a73e224c5292c8de0516732307070a1c0660d125c7d44553488700a4d7bddd3444299910e254ab984c3a219aea4adf1d0f8
2b7bd46cea4388ad1c12ab5d1ed8e1153d9c9f350a3246aad01c6873462b9ac05999ad5cc988826eafc3acae853a33b7ba11cd1445875ba1b236b1399483c90b
d560b0b0263435085a21b0f22a9cf9356b38ec6046026d77eba3dc2dc60b17e92219e180643ed27acffba86e9c94c7ca9c225a0f1b0cfae0788ad54adc5a9aec
1b703b8b93caec1a0bd8e5de7b132fe5113cf312503b998e2c2927274bd051db6b35979b1ef271daf6c6704e86c73805af4bdd476216c26593af840dfb5393d9
64f9cc9bad5c313709ea70f561ed3ea7b053075221d51696910d0d339585004b34272bff7213cc7a510a5454a3b349b1b206c1f0af490176745d4bc663e2abb2
b34b23da76f6352ba57ca2881844c1111ab189d8c7e07e1daaa04f40255c77988aa05fe06e4e5bdb4cb9c5394bbaf28d98c1d971ccd20867e556a7689ec9166e
0a522183792b8907ba55ca6e943bbf2a26e52f48957218ffcf54d1fb09dc3eac04da033e5c0d0b8c74a6b43d2e54c4a10aa511f5fb021a07533b205ae07e17a6
21a8e082dafc17e450ffb739676998b48643a4daa7211214f623150942f6a02c99e83b85583ddbbb2c4996113211551257a656ec1139246ca86be0aadedb3d14
41a89b6a929501833b197fee7b9641a3503739e57c732a59b1f7da1cf8a73b1f9bcca0945b874d4393dbbf10b1680f66bbaa5d6f96e77b6f59113d316bb31a79
5600b3d256d0cad2fe354538e7566b2bd69cc6cbcd5c38f0e2bcc63058344429dc2121fd07f63f2a7c66bf76e80d75c8f7a1b622f878a18941d840545fb28d07
d205d20e8ea071b283369834296bdaac75d256cb37eb0bee740bbe278cad253b8bbfcf69eca23973d939b97891c6ce2cecd8da8e2d343578f6648ac2d0383fc8
18c798cf64e52f597c740f1cbd05df0c264c49134cf09d4a60e8a107260f20f92d47b374e32f000000ffff0300504b0304140006000800000021000dd1909fb6
0000001b010000270000007468656d652f7468656d652f5f72656c732f7468656d654d616e616765722e786d6c2e72656c73848f4d0ac2301484f78277086f6f
d3ba109126dd88d0add40384e4350d363f2451eced0dae2c082e8761be9969bb979dc9136332de3168aa1a083ae995719ac16db8ec8e4052164e89d93b64b060
828e6f37ed1567914b284d262452282e3198720e274a939cd08a54f980ae38a38f56e422a3a641c8bbd048f7757da0f19b017cc524bd62107bd5001996509aff
b3fd381a89672f1f165dfe514173d9850528a2c6cce0239baa4c04ca5bbabac4df000000ffff0300504b01022d0014000600080000002100828abc13fa000000
1c0200001300000000000000000000000000000000005b436f6e74656e745f54797065735d2e786d6c504b01022d0014000600080000002100a5d6a7e7c00000
00360100000b000000000000000000000000002b0100005f72656c732f2e72656c73504b01022d00140006000800000021006b799616830000008a0000001c00
000000000000000000000000140200007468656d652f7468656d652f7468656d654d616e616765722e786d6c504b01022d001400060008000000210030dd4329
a8060000a41b00001600000000000000000000000000d10200007468656d652f7468656d652f7468656d65312e786d6c504b01022d0014000600080000002100
0dd1909fb60000001b0100002700000000000000000000000000ad0900007468656d652f7468656d652f5f72656c732f7468656d654d616e616765722e786d6c2e72656c73504b050600000000050005005d010000a80a00000000}
{\*\colorschememapping 3c3f786d6c2076657273696f6e3d22312e302220656e636f64696e673d225554462d3822207374616e64616c6f6e653d22796573223f3e0d0a3c613a636c724d
617020786d6c6e733a613d22687474703a2f2f736368656d61732e6f70656e786d6c666f726d6174732e6f72672f64726177696e676d6c2f323030362f6d6169
6e22206267313d226c743122207478313d22646b3122206267323d226c743222207478323d22646b322220616363656e74313d22616363656e74312220616363
656e74323d22616363656e74322220616363656e74333d22616363656e74332220616363656e74343d22616363656e74342220616363656e74353d22616363656e74352220616363656e74363d22616363656e74362220686c696e6b3d22686c696e6b2220666f6c486c696e6b3d22666f6c486c696e6b222f3e}
{\*\latentstyles\lsdstimax267\lsdlockeddef0\lsdsemihiddendef1\lsdunhideuseddef1\lsdqformatdef0\lsdprioritydef99{\lsdlockedexcept \lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority0 \lsdlocked0 Normal;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority9 \lsdlocked0 heading 1;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 2;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 3;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 4;
\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 5;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 6;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 7;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 8;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 9;
\lsdpriority39 \lsdlocked0 toc 1;\lsdpriority39 \lsdlocked0 toc 2;\lsdpriority39 \lsdlocked0 toc 3;\lsdpriority39 \lsdlocked0 toc 4;\lsdpriority39 \lsdlocked0 toc 5;\lsdpriority39 \lsdlocked0 toc 6;\lsdpriority39 \lsdlocked0 toc 7;
\lsdpriority39 \lsdlocked0 toc 8;\lsdpriority39 \lsdlocked0 toc 9;\lsdqformat1 \lsdpriority35 \lsdlocked0 caption;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority10 \lsdlocked0 Title;\lsdpriority1 \lsdlocked0 Default Paragraph Font;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority11 \lsdlocked0 Subtitle;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority22 \lsdlocked0 Strong;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority20 \lsdlocked0 Emphasis;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority59 \lsdlocked0 Table Grid;\lsdunhideused0 \lsdlocked0 Placeholder Text;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority1 \lsdlocked0 No Spacing;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading;\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List;\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List;\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List;\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid;\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 1;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 1;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 1;\lsdunhideused0 \lsdlocked0 Revision;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority34 \lsdlocked0 List Paragraph;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority29 \lsdlocked0 Quote;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority30 \lsdlocked0 Intense Quote;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 1;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 1;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 3;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 3;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 3;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 3;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 3;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 4;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 4;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 4;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 4;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 5;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 5;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 5;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 5;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 5;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 6;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 6;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 6;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 6;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 6;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority19 \lsdlocked0 Subtle Emphasis;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority21 \lsdlocked0 Intense Emphasis;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority31 \lsdlocked0 Subtle Reference;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority32 \lsdlocked0 Intense Reference;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority33 \lsdlocked0 Book Title;\lsdpriority37 \lsdlocked0 Bibliography;\lsdqformat1 \lsdpriority39 \lsdlocked0 TOC Heading;}}{\*\datastore 010500000200000018000000
4d73786d6c322e534158584d4c5265616465722e352e3000000000000000000000060000
d0cf11e0a1b11ae1000000000000000000000000000000003e000300feff090006000000000000000000000001000000010000000000000000100000feffffff00000000feffffff0000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
fffffffffffffffffdfffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffff52006f006f007400200045006e00740072007900000000000000000000000000000000000000000000000000000000000000000000000000000000000000000016000500ffffffffffffffffffffffffec69d9888b8b3d4c859eaf6cd158be0f000000000000000000000000e004
b1556ececb01feffffff00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffff00000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffff0000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffff000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000105000000000000}}
@@ -0,0 +1,465 @@
//
// (C) Copyright 2003-2019 by Autodesk, Inc.
//
// Permission to use, copy, modify, and distribute this software in
// object code form for any purpose and without fee is hereby granted,
// provided that the above copyright notice appears in all copies and
// that both that copyright notice and the limited warranty and
// restricted rights notice below appear in all supporting
// documentation.
//
// AUTODESK PROVIDES THIS PROGRAM "AS IS" AND WITH ALL FAULTS.
// AUTODESK SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. AUTODESK, INC.
// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
// UNINTERRUPTED OR ERROR FREE.
//
// Use, duplication, or disclosure by the U.S. Government is subject to
// restrictions set forth in FAR 52.227-19 (Commercial Computer
// Software - Restricted Rights) and DFAR 252.227-7013(c)(1)(ii)
// (Rights in Technical Data and Computer Software), as applicable.
//
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Autodesk.Revit.DB;
using Autodesk.Revit.UI;
using Autodesk.Revit.DB.ExtensibleStorage;
using System.Reflection;
namespace ExtensibleStorageManager
{
/// <summary>
/// An enum to select which sample schema to create.
/// </summary>
public enum SampleSchemaComplexity
{
SimpleExample =1,
ComplexExample = 2
}
/// <summary>
/// A static class that issues sample commands to a SchemaWrapper to demonstrate
/// schema and data storage.
/// </summary>
///
public static class StorageCommand
{
#region Create new sample schemas and write data to them
/// <summary>
/// Creates a new sample Schema, creates an instance of that Schema (an Entity) in the given element,
/// sets data on that element's entity, and exports the schema to a given XML file.
/// </summary>
/// <returns>A new SchemaWrapper</returns>
public static SchemaWrapperTools.SchemaWrapper CreateSetAndExport(Element storageElement, string xmlPathOut, Guid schemaId, AccessLevel readAccess, AccessLevel writeAccess, string vendorId, string applicationId, string name, string documentation, SampleSchemaComplexity schemaComplexity)
{
#region Start a new transaction, and create a new Schema
if (Schema.Lookup(schemaId) != null)
{
throw new Exception("A Schema with this Guid already exists in this document -- another one cannot be created.");
}
Transaction storageWrite = new Transaction(storageElement.Document, "storageWrite");
storageWrite.Start();
//Create a new schema.
SchemaWrapperTools.SchemaWrapper mySchemaWrapper = SchemaWrapperTools.SchemaWrapper.NewSchema(schemaId, readAccess, writeAccess, vendorId, applicationId, name, documentation);
mySchemaWrapper.SetXmlPath(xmlPathOut);
#endregion
Entity storageElementEntityWrite = null;
//Create some sample schema fields. There are two sample schemas hard coded here, "simple" and "complex."
switch (schemaComplexity)
{
case SampleSchemaComplexity.SimpleExample:
SimpleSchemaAndData(mySchemaWrapper, out storageElementEntityWrite);
break;
case SampleSchemaComplexity.ComplexExample:
ComplexSchemaAndData(mySchemaWrapper, storageElement, xmlPathOut, schemaId, readAccess, writeAccess, vendorId, applicationId, name, documentation, out storageElementEntityWrite);
break;
}
#region Store the main entity in an element, save the Serializeable SchemaWrapper to xml, and finish the transaction
storageElement.SetEntity(storageElementEntityWrite);
TransactionStatus storageResult = storageWrite.Commit();
if (storageResult != TransactionStatus.Committed)
{
throw new Exception("Error storing Schema. Transaction status: " + storageResult.ToString());
}
else
{
mySchemaWrapper.ToXml(xmlPathOut);
return mySchemaWrapper;
}
#endregion
}
#region Helper methods for CreateSetAndExport
/// <summary>
/// Adds several small, simple fields to a SchemaWrapper and Entity
/// </summary>
private static void SimpleSchemaAndData(SchemaWrapperTools.SchemaWrapper mySchemaWrapper, out Entity storageElementEntityWrite)
{
//Create some sample fields.
mySchemaWrapper.AddField<int>(int0Name, new ForgeTypeId(), null);
mySchemaWrapper.AddField<short>(short0Name, new ForgeTypeId(), null);
mySchemaWrapper.AddField<double>(double0Name, SpecTypeId.Length, null);
mySchemaWrapper.AddField<float>(float0Name, SpecTypeId.Length, null);
mySchemaWrapper.AddField<bool>(bool0Name, new ForgeTypeId(), null);
mySchemaWrapper.AddField<string>(string0Name, new ForgeTypeId(), null);
//Generate the Autodesk.Revit.DB.ExtensibleStorage.Schema.
mySchemaWrapper.FinishSchema();
//Get the fields
Field fieldInt0 = mySchemaWrapper.GetSchema().GetField(int0Name);
Field fieldShort0 = mySchemaWrapper.GetSchema().GetField(short0Name);
Field fieldDouble0 = mySchemaWrapper.GetSchema().GetField(double0Name);
Field fieldFloat0 = mySchemaWrapper.GetSchema().GetField(float0Name);
Field fieldBool0 = mySchemaWrapper.GetSchema().GetField(bool0Name);
Field fieldString0 = mySchemaWrapper.GetSchema().GetField(string0Name);
storageElementEntityWrite = null;
//Create a new entity of the given Schema
storageElementEntityWrite = new Entity(mySchemaWrapper.GetSchema());
//Set data in the entity.
storageElementEntityWrite.Set<int>(fieldInt0, 5);
storageElementEntityWrite.Set<short>(fieldShort0, 2);
storageElementEntityWrite.Set<double>(fieldDouble0, 7.1, UnitTypeId.Meters);
storageElementEntityWrite.Set<float>(fieldFloat0, 3.1f, UnitTypeId.Meters);
storageElementEntityWrite.Set(fieldBool0, false);
storageElementEntityWrite.Set(fieldString0, "hello");
}
/// <summary>
/// Adds a simple fields, arrays, maps, subEntities, and arrays and maps of subEntities to a SchemaWrapper and Entity
/// </summary>
private static void ComplexSchemaAndData(SchemaWrapperTools.SchemaWrapper mySchemaWrapper, Element storageElement, string xmlPathOut, Guid schemaId, AccessLevel readAccess, AccessLevel writeAccess, string vendorId, string applicationId, string name, string documentation, out Entity storageElementEntityWrite)
{
#region Add Fields to the SchemaWrapper
mySchemaWrapper.AddField<int>(int0Name, new ForgeTypeId(), null);
mySchemaWrapper.AddField<short>(short0Name, new ForgeTypeId(), null);
mySchemaWrapper.AddField<double>(double0Name, SpecTypeId.Length, null);
mySchemaWrapper.AddField<float>(float0Name, SpecTypeId.Length, null);
mySchemaWrapper.AddField<bool>(bool0Name, new ForgeTypeId(), null);
mySchemaWrapper.AddField<string>(string0Name, new ForgeTypeId(), null);
mySchemaWrapper.AddField<ElementId>(id0Name, new ForgeTypeId(), null);
mySchemaWrapper.AddField<XYZ>(point0Name, SpecTypeId.Length, null);
mySchemaWrapper.AddField<UV>(uv0Name, SpecTypeId.Length, null);
mySchemaWrapper.AddField<Guid>(guid0Name, new ForgeTypeId(), null);
//Note that we use IDictionary<> for map types and IList<> for array types
mySchemaWrapper.AddField<IDictionary<string, string>>(map0Name, new ForgeTypeId(), null);
mySchemaWrapper.AddField<IList<bool>>(array0Name, new ForgeTypeId(), null);
//Create a sample subEntity
SchemaWrapperTools.SchemaWrapper mySubSchemaWrapper0 = SchemaWrapperTools.SchemaWrapper.NewSchema(subEntityGuid0, readAccess, writeAccess, vendorId, applicationId, entity0Name, "A sub entity");
mySubSchemaWrapper0.AddField<int>("subInt0", new ForgeTypeId(), null);
mySubSchemaWrapper0.FinishSchema();
Entity subEnt0 = new Entity(mySubSchemaWrapper0.GetSchema());
subEnt0.Set<int>(mySubSchemaWrapper0.GetSchema().GetField("subInt0"), 11);
mySchemaWrapper.AddField<Entity>(entity0Name, new ForgeTypeId(), mySubSchemaWrapper0);
//
//Create a sample map of subEntities (An IDictionary<> with key type "int" and value type "Entity")
//
//Create a new sample schema.
SchemaWrapperTools.SchemaWrapper mySubSchemaWrapper1_Map = SchemaWrapperTools.SchemaWrapper.NewSchema(subEntityGuid_Map1, readAccess, writeAccess, vendorId, applicationId, map1Name, "A map of int to Entity");
mySubSchemaWrapper1_Map.AddField<int>("subInt1", new ForgeTypeId(), null);
mySubSchemaWrapper1_Map.FinishSchema();
//Create a new sample Entity.
Entity subEnt1 = new Entity(mySubSchemaWrapper1_Map.GetSchema());
//Set data in that entity.
subEnt1.Set<int>(mySubSchemaWrapper1_Map.GetSchema().GetField("subInt1"), 22);
//Add a new map field to the top-level Schema. We will add the entity we just created after all top-level
//fields are created.
mySchemaWrapper.AddField<IDictionary<int, Entity>>(map1Name, new ForgeTypeId(), mySubSchemaWrapper1_Map);
//
//Create a sample array of subentities (An IList<> of type "Entity")
//
//Create a new sample schema
SchemaWrapperTools.SchemaWrapper mySubSchemaWrapper2_Array = SchemaWrapperTools.SchemaWrapper.NewSchema(subEntityGuid_Array2, readAccess, writeAccess, vendorId, applicationId, array1Name, "An array of Entities");
mySubSchemaWrapper2_Array.AddField<int>("subInt2", new ForgeTypeId(), null);
mySubSchemaWrapper2_Array.FinishSchema();
//Create a new sample Entity.
Entity subEnt2 = new Entity(mySubSchemaWrapper2_Array.GetSchema());
//Set the data in that Entity.
subEnt2.Set<int>(mySubSchemaWrapper2_Array.GetSchema().GetField("subInt2"), 33);
//Add a new array field to the top-level Schema We will add the entity we just crated after all top-level fields
//are created.
mySchemaWrapper.AddField<IList<Entity>>(array1Name, new ForgeTypeId(), mySubSchemaWrapper2_Array);
#endregion
#region Populate the Schema in the SchemaWrapper with data
mySchemaWrapper.FinishSchema();
#endregion
#region Create a new entity to store an instance of schema data
storageElementEntityWrite = null;
storageElementEntityWrite = new Entity(mySchemaWrapper.GetSchema());
#endregion
#region Get fields and set data in them
Field fieldInt0 = mySchemaWrapper.GetSchema().GetField(int0Name);
Field fieldShort0 = mySchemaWrapper.GetSchema().GetField(short0Name);
Field fieldDouble0 = mySchemaWrapper.GetSchema().GetField(double0Name);
Field fieldFloat0 = mySchemaWrapper.GetSchema().GetField(float0Name);
Field fieldBool0 = mySchemaWrapper.GetSchema().GetField(bool0Name);
Field fieldString0 = mySchemaWrapper.GetSchema().GetField(string0Name);
Field fieldId0 = mySchemaWrapper.GetSchema().GetField(id0Name);
Field fieldPoint0 = mySchemaWrapper.GetSchema().GetField(point0Name);
Field fieldUv0 = mySchemaWrapper.GetSchema().GetField(uv0Name);
Field fieldGuid0 = mySchemaWrapper.GetSchema().GetField(guid0Name);
Field fieldMap0 = mySchemaWrapper.GetSchema().GetField(map0Name);
Field fieldArray0 = mySchemaWrapper.GetSchema().GetField(array0Name);
Field fieldEntity0 = mySchemaWrapper.GetSchema().GetField(entity0Name);
Field fieldMap1 = mySchemaWrapper.GetSchema().GetField(map1Name);
Field fieldArray1 = mySchemaWrapper.GetSchema().GetField(array1Name);
storageElementEntityWrite.Set<int>(fieldInt0, 5);
storageElementEntityWrite.Set<short>(fieldShort0, 2);
storageElementEntityWrite.Set<double>(fieldDouble0, 7.1, UnitTypeId.Meters);
storageElementEntityWrite.Set<float>(fieldFloat0, 3.1f, UnitTypeId.Meters);
storageElementEntityWrite.Set(fieldBool0, false);
storageElementEntityWrite.Set(fieldString0, "hello");
storageElementEntityWrite.Set(fieldId0, storageElement.Id);
storageElementEntityWrite.Set(fieldPoint0, new XYZ(1, 2, 3), UnitTypeId.Meters);
storageElementEntityWrite.Set(fieldUv0, new UV(1, 2), UnitTypeId.Meters);
storageElementEntityWrite.Set(fieldGuid0, new Guid("D8301329-F207-43B8-8AA1-634FD344F350"));
//Note that we must pass an IDictionary<>, not a Dictionary<> to Set().
IDictionary<string, string> myMap0 = new Dictionary<string, string>();
myMap0.Add("mykeystr", "myvalstr");
storageElementEntityWrite.Set(fieldMap0, myMap0);
//Note that we must pass an IList<>, not a List<> to Set().
IList<bool> myBoolArrayList0 = new List<bool>();
myBoolArrayList0.Add(true);
myBoolArrayList0.Add(false);
storageElementEntityWrite.Set(fieldArray0, myBoolArrayList0);
storageElementEntityWrite.Set(fieldEntity0, subEnt0);
//Create a map of Entities
IDictionary<int, Entity> myMap1 = new Dictionary<int, Entity>();
myMap1.Add(5, subEnt1);
//Set the map of Entities.
storageElementEntityWrite.Set(fieldMap1, myMap1);
//Create a list of entities
IList<Entity> myEntArrayList1 = new List<Entity>();
myEntArrayList1.Add(subEnt2);
myEntArrayList1.Add(subEnt2);
//Set the list of entities.
storageElementEntityWrite.Set(fieldArray1, myEntArrayList1);
#endregion
}
#endregion
#endregion
#region Create and query SchemaWrappers from existing schemas or XML
/// <summary>
/// Given an Autodesk.Revit.DB.ExtensibleStorage.Schema that already exists,
/// create a SchemaWrapper containing that Schema's data.
/// </summary>
/// <param name="schemaId">The Guid of the existing Schema</param>
public static void CreateWrapperFromSchema(Guid schemaId, out SchemaWrapperTools.SchemaWrapper schemaWrapper)
{
Schema toLookup = Schema.Lookup(schemaId);
if (toLookup == null)
{
throw new Exception("Schema not found in current document.");
}
else
{
schemaWrapper = SchemaWrapperTools.SchemaWrapper.FromSchema(toLookup);
}
}
/// <summary>
/// Create a SchemaWrapper from a Schema Guid and try to find an Entity of a matching Guid
/// in a given Element. If successfull, try to change the data in that Entity.
/// </summary>
/// <param name="storageElement"></param>
/// <param name="schemaId"></param>
/// <param name="schemaWrapper"></param>
public static void EditExistingData(Element storageElement, Guid schemaId, out SchemaWrapperTools.SchemaWrapper schemaWrapper)
{
//Try to find the schema in the active document.
Schema schemaLookup = Schema.Lookup(schemaId);
if (schemaLookup == null)
{
throw new Exception("Schema not found in current document.");
}
//Create a SchemaWrapper.
schemaWrapper = SchemaWrapperTools.SchemaWrapper.FromSchema(schemaLookup);
//Try to get an Entity of the given Schema
Entity storageElementEntityWrite = storageElement.GetEntity(schemaLookup);
if (storageElementEntityWrite.SchemaGUID != schemaId)
{
throw new Exception("SchemaID of found entity does not match the SchemaID passed to GetEntity.");
}
if (storageElementEntityWrite == null)
{
throw new Exception("Entity of given Schema not found.");
}
//Get the fields of the schema
Field fieldInt0 = schemaWrapper.GetSchema().GetField(int0Name);
Field fieldShort0 = schemaWrapper.GetSchema().GetField(short0Name);
Field fieldDouble0 = schemaWrapper.GetSchema().GetField(double0Name);
Field fieldFloat0 = schemaWrapper.GetSchema().GetField(float0Name);
Field fieldBool0 = schemaWrapper.GetSchema().GetField(bool0Name);
Field fieldString0 = schemaWrapper.GetSchema().GetField(string0Name);
//Edit the fields.
Transaction tStore = new Transaction(storageElement.Document, "tStore");
tStore.Start();
storageElementEntityWrite = null;
storageElementEntityWrite = new Entity(schemaWrapper.GetSchema());
storageElementEntityWrite.Set<int>(fieldInt0, 10);
storageElementEntityWrite.Set<short>(fieldShort0, 20);
storageElementEntityWrite.Set<double>(fieldDouble0, 14.2, UnitTypeId.Meters);
storageElementEntityWrite.Set<float>(fieldFloat0, 6.12f, UnitTypeId.Meters);
storageElementEntityWrite.Set(fieldBool0, true);
storageElementEntityWrite.Set(fieldString0, "goodbye");
//Set the entity back into the storage element.
storageElement.SetEntity(storageElementEntityWrite);
tStore.Commit();
}
/// <summary>
/// Given an element, try to find an entity containing instance data from a given Schema Guid.
/// </summary>
/// <param name="storageElement">The element to query</param>
/// <param name="schemaId">The id of the Schema to query</param>
public static void LookupAndExtractData(Element storageElement, Guid schemaId, out SchemaWrapperTools.SchemaWrapper schemaWrapper)
{
Schema schemaLookup = Schema.Lookup(schemaId);
if (schemaLookup == null)
{
throw new Exception("Schema not found in current document.");
}
schemaWrapper = SchemaWrapperTools.SchemaWrapper.FromSchema(schemaLookup);
Entity storageElementEntityRead = storageElement.GetEntity(schemaLookup);
if (storageElementEntityRead.SchemaGUID != schemaId)
{
throw new Exception("SchemaID of found entity does not match the SchemaID passed to GetEntity.");
}
if (storageElementEntityRead == null)
{
throw new Exception("Entity of given Schema not found.");
}
}
/// <summary>
/// Given an xml path containing serialized schema data, create a new Schema and SchemaWrapper
/// </summary>
public static void ImportSchemaFromXml(string path, out SchemaWrapperTools.SchemaWrapper sWrapper)
{
sWrapper = SchemaWrapperTools.SchemaWrapper.FromXml(path);
sWrapper.SetXmlPath(path);
}
#endregion
#region Helper methods
/// <summary>
/// Create a new pseudorandom Guid
/// </summary>
/// <returns></returns>
public static Guid NewGuid()
{
byte[] guidBytes = new byte[16];
Random randomGuidBytes = new Random(s_counter);
randomGuidBytes.NextBytes(guidBytes);
s_counter++;
return new Guid(guidBytes);
}
#endregion
#region Data
//A counter field used to assist in creating pseudorandom Guids
private static int s_counter = System.DateTime.Now.Second;
//Field names and schema guids used in sample schemas
private static string int0Name = "int0Name";
private static string double0Name = "double0Name";
private static string bool0Name = "bool0Name";
private static string string0Name = "string0Name";
private static string id0Name = "id0Name";
private static string point0Name = "point0Name";
private static string uv0Name = "uv0Name";
private static string float0Name = "float0Name";
private static string short0Name = "short0Name";
private static string guid0Name = "guid0Name";
private static string map0Name = "map0Name";
private static string array0Name = "array0Name";
private static Guid subEntityGuid0 = NewGuid();
private static string entity0Name = "entity0Name";
private static Guid subEntityGuid_Map1 = NewGuid();
private static string entity1Name_Map = "entity1Name_Map";
private static Guid subEntityGuid_Array2 = NewGuid();
private static string entity2Name_Array = "entity2Name_Array";
private static string array1Name = entity2Name_Array;
private static string map1Name = entity1Name_Map;
#endregion
}
}
@@ -0,0 +1,129 @@
<Window x:Class="ExtensibleStorageManager.UICommand"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Height="450" Width="780" Title="Extensible Storage Manager">
<DockPanel>
<StackPanel>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"></ColumnDefinition>
<ColumnDefinition Width="3*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Content="This application's Id"></Label>
<Label Name="m_label_applicationAppId" Grid.Column="1"></Label>
</Grid>
<Label Content="Schema Data" HorizontalAlignment="Center"></Label>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"></ColumnDefinition>
<ColumnDefinition Width="3*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Content="Path"></Label>
<Label Name="m_textBox_SchemaPath" Grid.Column="1" Background="LightGray"></Label>
</Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="4*"></ColumnDefinition>
<ColumnDefinition Width="10*"></ColumnDefinition>
<ColumnDefinition Width="2*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Content="SchemaId"></Label>
<TextBox Name="m_textBox_SchemaId" Grid.Column="1" Background="LightGray"></TextBox>
<Button Name="m_button_NewSchemaId" Grid.Column="2" Content="New Id" Click="m_button_NewSchemaId_Click"></Button>
</Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"></ColumnDefinition>
<ColumnDefinition Width="3*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Content="Name"></Label>
<TextBox Name="m_textBox_SchemaName" Grid.Column="1" Background="LightGray"></TextBox>
</Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"></ColumnDefinition>
<ColumnDefinition Width="3*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Content="Documentation"></Label>
<TextBox Name="m_textBox_SchemaDocumentation" Grid.Column="1" Background="LightGray"></TextBox>
</Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"></ColumnDefinition>
<ColumnDefinition Width="3*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Content="VendorId"></Label>
<TextBox Name="m_textBox_SchemaVendorId" Grid.Column="1" Background="LightGray"></TextBox>
</Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"></ColumnDefinition>
<ColumnDefinition Width="3*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Content="ApplicationId"></Label>
<TextBox Name="m_textBox_SchemaApplicationId" Grid.Column="1" Background="LightGray"></TextBox>
</Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"></ColumnDefinition>
<ColumnDefinition Width="3*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Content="Read Access"></Label>
<StackPanel Grid.Column="1" Orientation="Horizontal" HorizontalAlignment="Center">
<RadioButton Name="m_rb_ReadAccess_Application" VerticalAlignment="Center" HorizontalContentAlignment="Stretch" Content=" Application "></RadioButton>
<RadioButton Name="m_rb_ReadAccess_Public" VerticalAlignment="Center" HorizontalContentAlignment="Stretch" Content="Public " ></RadioButton>
<RadioButton Name="m_rb_ReadAccess_Vendor" VerticalAlignment="Center" HorizontalContentAlignment="Stretch" Content=" Vendor "></RadioButton>
</StackPanel>
</Grid>
<Grid>
<Grid.ColumnDefinitions>
<ColumnDefinition Width="1*"></ColumnDefinition>
<ColumnDefinition Width="3*"></ColumnDefinition>
</Grid.ColumnDefinitions>
<Label Grid.Column="0" Content="Write Access"></Label>
<StackPanel Grid.Column="1" Orientation="Horizontal" HorizontalAlignment="Center">
<RadioButton Name="m_rb_WriteAccess_Application" VerticalAlignment="Center" HorizontalContentAlignment="Stretch" Content=" Application "></RadioButton>
<RadioButton Name="m_rb_WriteAccess_Public" VerticalAlignment="Center" HorizontalContentAlignment="Stretch" Content="Public " ></RadioButton>
<RadioButton Name="m_rb_WriteAccess_Vendor" VerticalAlignment="Center" HorizontalContentAlignment="Stretch" Content=" Vendor "></RadioButton>
</StackPanel>
</Grid>
<Label Content="Commands" HorizontalAlignment="Center"></Label>
<Grid>
<Grid.RowDefinitions>
<RowDefinition></RowDefinition>
<RowDefinition></RowDefinition>
<RowDefinition></RowDefinition>
<RowDefinition></RowDefinition>
</Grid.RowDefinitions>
<Grid.ColumnDefinitions>
<ColumnDefinition></ColumnDefinition>
<ColumnDefinition></ColumnDefinition>
</Grid.ColumnDefinitions>
<StackPanel Grid.Row="0" Grid.Column="0">
<Button Name="m_button_CreateSetSave_Simple" ToolTip="Primitives only" Content="Create new schema, store data, save schema Xml - Simple" Click="m_button_CreateSetSaveSimple_Click"></Button>
<Button Name="m_button_EditExisting_Simple" ToolTip="Edit Existing" Content="Edit Existing Data - Simple" Click="m_button_EditExistingSimple_Click"></Button>
<Button Name="m_button_CreateSetSave_Complex" ToolTip="All types, including maps and lists of subEntities" Content="Create new schema, store data, save schema Xml - Complex" Click="m_button_CreateSetSaveComplex_Click"></Button>
</StackPanel>
<StackPanel Grid.Row="0" Grid.Column="1">
<Button Name="m_button_LookupExtract" Content="Look up schema and extract entity data" Click="m_button_LookupExtract_Click"></Button>
<Button Name="m_button_CreateWrapperFromSchema" Content="Create SchemaWrapper from Schema" Click="m_button_CreateWrapperFromSchema_Click"></Button>
<Button Name="m_button_CreateSchemaFromXml" Content="Create SchemaWrapper from Xml" Click="m_button_CreateSchemaFromXml_Click"></Button>
</StackPanel>
</Grid>
</StackPanel>
</DockPanel>
</Window>
@@ -0,0 +1,377 @@
using System;
using System.Windows;
using System.Windows.Controls;
using Autodesk.Revit.DB;
using Autodesk.Revit.DB.ExtensibleStorage;
using Autodesk.Revit.UI;
namespace ExtensibleStorageManager
{
/// <summary>
/// The main user dialog class for issuing sample commands to the a SchemaWrapper
/// </summary>
public partial class UICommand : Window
{
#region Constructor
/// <summary>
/// Create a new dialog object and store a reference to the active document and applicationID of this addin.
/// </summary>
public UICommand(Autodesk.Revit.DB.Document doc, string applicationId)
{
InitializeComponent();
this.Closing += new System.ComponentModel.CancelEventHandler(UICommand_Closing);
m_Document = doc;
//Create a new empty schemaWrapper.
m_SchemaWrapper = SchemaWrapperTools.SchemaWrapper.NewSchema(Guid.Empty, Autodesk.Revit.DB.ExtensibleStorage.AccessLevel.Public, Autodesk.Revit.DB.ExtensibleStorage.AccessLevel.Public, "adsk", applicationId, "schemaName", "Schema documentation");
this.m_label_applicationAppId.Content = applicationId;
UpdateUI();
}
#endregion
#region Helper methods
/// <summary>
/// Return a convenient recommended path to save schema files in.
/// </summary>
private string GetStartingXmlPath()
{
string currentAssemby = System.Reflection.Assembly.GetAssembly(this.GetType()).Location;
return System.IO.Path.Combine(System.IO.Path.GetDirectoryName(currentAssemby), "schemas");
}
/// <summary>
/// Synchronize all UI controls in the dialog with the data in m_SchemaWrapper.
/// </summary>
private void UpdateUI()
{
this.m_textBox_SchemaApplicationId.Text = m_SchemaWrapper.Data.ApplicationId;
this.m_textBox_SchemaVendorId.Text = m_SchemaWrapper.Data.VendorId;
this.m_textBox_SchemaPath.Content = m_SchemaWrapper.GetXmlPath();
this.m_textBox_SchemaName.Text = m_SchemaWrapper.Data.Name;
this.m_textBox_SchemaDocumentation.Text = m_SchemaWrapper.Data.Documentation;
this.m_textBox_SchemaId.Text = m_SchemaWrapper.Data.SchemaId;
if (this.m_textBox_SchemaId.Text == Guid.Empty.ToString())
this.m_textBox_SchemaId.Text = Application.LastGuid;
switch (m_SchemaWrapper.Data.ReadAccess)
{
case AccessLevel.Application:
{
m_rb_ReadAccess_Application.IsChecked = true;
break;
}
case AccessLevel.Public:
{
m_rb_ReadAccess_Public.IsChecked = true;
break;
}
case AccessLevel.Vendor:
{
m_rb_ReadAccess_Vendor.IsChecked = true;
break;
}
}
switch (m_SchemaWrapper.Data.WriteAccess)
{
case AccessLevel.Application:
{
m_rb_WriteAccess_Application.IsChecked = true;
break;
}
case AccessLevel.Public:
{
m_rb_WriteAccess_Public.IsChecked = true;
break;
}
case AccessLevel.Vendor:
{
m_rb_WriteAccess_Vendor.IsChecked = true;
break;
}
}
}
/// <summary>
/// Retrieve AccessLevel enums for read and write permissions from the UI
/// </summary>
private void GetUIAccessLevels(out AccessLevel read, out AccessLevel write)
{
read = AccessLevel.Public;
write = AccessLevel.Public;
if (m_rb_ReadAccess_Application.IsChecked == true)
read = AccessLevel.Application;
else if (m_rb_ReadAccess_Public.IsChecked == true)
read = AccessLevel.Public;
else
read = AccessLevel.Vendor;
if (m_rb_WriteAccess_Application.IsChecked == true)
write = AccessLevel.Application;
else if (m_rb_WriteAccess_Public.IsChecked == true)
write = AccessLevel.Public;
else
write = AccessLevel.Vendor;
}
/// <summary>
/// Ensure that the values in the two text fields in the dialogs meant for Guids evaluate
/// to valid Guids.
/// </summary>
private bool ValidateGuids()
{
bool retval = true;
try
{
Guid schemaId = new Guid(this.m_textBox_SchemaId.Text);
Guid applicationId = new Guid(this.m_textBox_SchemaApplicationId.Text);
}
catch (Exception)
{
retval = false;
}
return retval;
}
#endregion
#region UI Handlers
//Store the Guid of the last-used schema in the Application object for convenient access
//later if the user re-creates and displays this dialog again.
void UICommand_Closing(object sender, System.ComponentModel.CancelEventArgs e)
{
Application.LastGuid = m_textBox_SchemaId.Text;
}
//Put a new, arbitrary Guid in the schema text box.
private void m_button_NewSchemaId_Click(object sender, RoutedEventArgs e)
{
m_textBox_SchemaId.Text = StorageCommand.NewGuid().ToString();
}
/// <summary>
/// Handler for the "Create a simple schema" button.
/// </summary>
private void m_button_CreateSetSaveSimple_Click(object sender, RoutedEventArgs e)
{
CreateSetSave(SampleSchemaComplexity.SimpleExample);
}
/// <summary>
/// Handler for the "Create a complex schema" button.
/// </summary>
private void m_button_CreateSetSaveComplex_Click(object sender, RoutedEventArgs e)
{
CreateSetSave(SampleSchemaComplexity.ComplexExample);
}
/// <summary>
/// Creates a sample schema, populates it with sample data, and saves it to an XML file
/// </summary>
/// <param name="schemaComplexity">The example schema to create</param>
private void CreateSetSave(SampleSchemaComplexity schemaComplexity)
{
//Get read-write access levels and schema and application Ids from the active dialog
AccessLevel read;
AccessLevel write;
GetUIAccessLevels(out read, out write);
if (!ValidateGuids())
{
TaskDialog.Show("ExtensibleStorage Manager", "Invalid Schema or ApplicationId Guid.");
return;
}
//Get a pathname for an XML file from the user.
Microsoft.Win32.SaveFileDialog sfd = new Microsoft.Win32.SaveFileDialog();
sfd.DefaultExt = ".xml";
sfd.Filter = "SchemaWrapper Xml files (*.xml)|*.xml";
sfd.InitialDirectory = GetStartingXmlPath();
sfd.FileName = this.m_textBox_SchemaName.Text + "_" + this.m_textBox_SchemaVendorId.Text + "___" + this.m_textBox_SchemaId.Text.Substring(31) + ".xml";
Nullable<bool> result = sfd.ShowDialog();
if ((result.HasValue) && (result == true))
{
try
{
//Create a new sample SchemaWrapper, schema, and Entity and store it in the current document's ProjectInformation element.
m_SchemaWrapper = StorageCommand.CreateSetAndExport(m_Document.ProjectInformation, sfd.FileName, new Guid(this.m_textBox_SchemaId.Text), read, write, this.m_textBox_SchemaVendorId.Text, this.m_textBox_SchemaApplicationId.Text, this.m_textBox_SchemaName.Text, this.m_textBox_SchemaDocumentation.Text, schemaComplexity);
}
catch (Exception ex)
{
TaskDialog.Show("ExtensibleStorage Manager", "Could not Create Schema. " + ex.ToString());
return;
}
UpdateUI();
//Display the schema fields and sample data we just created in a dialog.
ExtensibleStorageManager.UIData dataDialog = new ExtensibleStorageManager.UIData();
string schemaData = this.m_SchemaWrapper.ToString();
string entityData = this.m_SchemaWrapper.GetSchemaEntityData(m_Document.ProjectInformation.GetEntity(m_SchemaWrapper.GetSchema()));
string allData = "Schema: " + Environment.NewLine + schemaData + Environment.NewLine + Environment.NewLine + "Entity" + Environment.NewLine + entityData;
dataDialog.SetData(allData);
dataDialog.ShowDialog();
}
}
/// <summary>
/// Handler for the "Create Wrapper from Schema" button
/// </summary>
private void m_button_CreateWrapperFromSchema_Click(object sender, RoutedEventArgs e)
{
try
{
//Given a Guid that corresponds to a schema that already exists in a document, create a SchemaWrapper
//from it and display its top-level data in the dialog.
StorageCommand.CreateWrapperFromSchema(new Guid(m_textBox_SchemaId.Text), out m_SchemaWrapper);
UpdateUI();
}
catch (Exception ex)
{
TaskDialog.Show("ExtensibleStorage Manager", "Could not Create SchemaWrapper from Schema. " + ex.ToString());
return;
}
//Display all of the schema's field data in a separate dialog.
ExtensibleStorageManager.UIData dataDialog = new ExtensibleStorageManager.UIData();
dataDialog.SetData(m_SchemaWrapper.ToString());
dataDialog.ShowDialog();
}
/// <summary>
/// Handler for the "Look up and extract" button
/// </summary>
private void m_button_LookupExtract_Click(object sender, RoutedEventArgs e)
{
try
{
//Given a Guid that corresponds to a schema that already exists in a document, create a SchemaWrapper
//from it and display its top-level data in the dialog.
StorageCommand.LookupAndExtractData(m_Document.ProjectInformation, new Guid(m_textBox_SchemaId.Text), out m_SchemaWrapper);
}
catch (Exception ex)
{
TaskDialog.Show("ExtensibleStorage Manager", "Could not extract data from Schema. " + ex.ToString());
return;
}
UpdateUI();
ExtensibleStorageManager.UIData dataDialog = new ExtensibleStorageManager.UIData();
//Get and display the schema field data and the actual entity data in a separate dialog.
string schemaData = this.m_SchemaWrapper.ToString();
string entityData = this.m_SchemaWrapper.GetSchemaEntityData(m_Document.ProjectInformation.GetEntity(m_SchemaWrapper.GetSchema()));
string allData = "Schema: " + Environment.NewLine + schemaData + Environment.NewLine + Environment.NewLine + "Entity" + Environment.NewLine + entityData;
dataDialog.SetData(allData);
dataDialog.ShowDialog();
}
/// <summary>
/// Handler for the "Create Schema from XML" button
/// </summary>
private void m_button_CreateSchemaFromXml_Click(object sender, RoutedEventArgs e)
{
//Prompt the user for an xml file containing a serialized schema.
Microsoft.Win32.OpenFileDialog ofd = new Microsoft.Win32.OpenFileDialog();
ofd.InitialDirectory = GetStartingXmlPath();
ofd.DefaultExt = ".xml";
ofd.Filter = "SchemaWrapper Xml files (*.xml)|*.xml";
Nullable<bool> result = ofd.ShowDialog();
if (( result.HasValue) && (result == true))
{
try
{
//Given an xml file containing schema data, create a new SchemaWrapper object
StorageCommand.ImportSchemaFromXml(ofd.FileName, out m_SchemaWrapper);
}
catch (Exception ex)
{
TaskDialog.Show("ExtensibleStorage Manager", "Could not import Schema from Xml. " + ex.ToString());
return;
}
//Display the top level schema data in the dialog.
UpdateUI();
//Display the field data of the schema in a separate dialog.
ExtensibleStorageManager.UIData dataDialog = new ExtensibleStorageManager.UIData();
dataDialog.SetData(m_SchemaWrapper.ToString());
dataDialog.ShowDialog();
}
}
/// <summary>
/// Handler for the "Edit Exisiting Data" button
/// </summary>
private void m_button_EditExistingSimple_Click(object sender, RoutedEventArgs e)
{
try
{
///Given a guid corresponding to a Schema with Entity data in the current document's ProjectInformation element,
///change the entity data to new data, (assuming that the schemas and schema guids are identical).
StorageCommand.EditExistingData(m_Document.ProjectInformation, new Guid(m_textBox_SchemaId.Text), out m_SchemaWrapper);
}
catch (Exception ex)
{
TaskDialog.Show("ExtensibleStorage Manager", "Could not extract data from Schema. " + ex.ToString());
return;
}
UpdateUI();
///Display the schema fields and new data in a separate dialog.
ExtensibleStorageManager.UIData dataDialog = new ExtensibleStorageManager.UIData();
string schemaData = this.m_SchemaWrapper.ToString();
string entityData = this.m_SchemaWrapper.GetSchemaEntityData(m_Document.ProjectInformation.GetEntity(m_SchemaWrapper.GetSchema()));
string allData = "Schema: " + Environment.NewLine + schemaData + Environment.NewLine + Environment.NewLine + "Entity" + Environment.NewLine + entityData;
dataDialog.SetData(allData);
dataDialog.ShowDialog();
}
#endregion
#region Properties
/// <summary>
/// The active document in Revit that the dialog queries for Schema and Entity data.
/// </summary>
public Autodesk.Revit.DB.Document Document
{
get { return m_Document; }
set { m_Document = value; }
}
#endregion
#region Data
/// <summary>
/// The object that provides high level serialization access to an Autodesk.Revit.DB.ExtensibleStorage.Schema
/// </summary>
private SchemaWrapperTools.SchemaWrapper m_SchemaWrapper;
private Autodesk.Revit.DB.Document m_Document;
#endregion
}
}
@@ -0,0 +1,11 @@
<Window x:Class="ExtensibleStorageManager.UIData"
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
Height="600" Width="900" Title="Data">
<DockPanel>
<TextBox Name="m_tb_Data" HorizontalScrollBarVisibility="Visible" VerticalScrollBarVisibility="Visible"></TextBox>
</DockPanel>
</Window>
@@ -0,0 +1,35 @@
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Data;
using System.Windows.Documents;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Imaging;
using System.Windows.Navigation;
using System.Windows.Shapes;
namespace ExtensibleStorageManager
{
/// <summary>
/// A class for a Window with a TextBox for displaying many lines of text data.
/// </summary>
public partial class UIData : Window
{
public UIData()
{
InitializeComponent();
}
public void SetData(string data)
{
this.m_tb_Data.Text = data;
}
}
}
@@ -0,0 +1,44 @@
<?xml version="1.0"?>
<SchemaWrapper xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<Data>
<DataList>
<FieldData>
<Name>int0Name</Name>
<Type>System.Int32</Type>
<Spec></Spec>
</FieldData>
<FieldData>
<Name>short0Name</Name>
<Type>System.Int16</Type>
<Spec></Spec>
</FieldData>
<FieldData>
<Name>double0Name</Name>
<Type>System.Double</Type>
<Spec>autodesk.spec.aec:length-1.0.0</Spec>
</FieldData>
<FieldData>
<Name>float0Name</Name>
<Type>System.Single</Type>
<Spec>autodesk.spec.aec:length-1.0.0</Spec>
</FieldData>
<FieldData>
<Name>bool0Name</Name>
<Type>System.Boolean</Type>
<Spec></Spec>
</FieldData>
<FieldData>
<Name>string0Name</Name>
<Type>System.String</Type>
<Spec></Spec>
</FieldData>
</DataList>
<SchemaId>d07961c1-6958-9ecc-4ebf-6ba84b378630</SchemaId>
<ReadAccess>Public</ReadAccess>
<WriteAccess>Public</WriteAccess>
<VendorId>adsk</VendorId>
<ApplicationId>dec00020-2010-4338-8de4-addcadcadcad</ApplicationId>
<Documentation>A simple schema that can be deserialized into an Autodesk.Revit.DB.ExtensibleStorage.Schema</Documentation>
<Name>aSimpleSchema</Name>
</Data>
</SchemaWrapper>
@@ -0,0 +1,143 @@
//
// (C) Copyright 2003-2019 by Autodesk, Inc. All rights reserved.
//
// Permission to use, copy, modify, and distribute this software in
// object code form for any purpose and without fee is hereby granted
// provided that the above copyright notice appears in all copies and
// that both that copyright notice and the limited warranty and
// restricted rights notice below appear in all supporting
// documentation.
//
// AUTODESK PROVIDES THIS PROGRAM 'AS IS' AND WITH ALL ITS FAULTS.
// AUTODESK SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. AUTODESK, INC.
// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
// UNINTERRUPTED OR ERROR FREE.
//
// Use, duplication, or disclosure by the U.S. Government is subject to
// restrictions set forth in FAR 52.227-19 (Commercial Computer
// Software - Restricted Rights) and DFAR 252.227-7013(c)(1)(ii)
// (Rights in Technical Data and Computer Software), as applicable.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Autodesk.Revit.DB;
using Autodesk.Revit.UI;
using Autodesk.Revit.DB.ExtensibleStorage;
using System.Xml.Serialization;
using System.Runtime.Serialization;
using System.IO;
namespace SchemaWrapperTools
{
/// <summary>
/// A class to store schema field information
/// </summary>
[Serializable]
public class FieldData
{
#region Constructors
/// <summary>
/// For serialization only -- Do not use.
/// </summary>
internal FieldData() { }
/// <summary>
/// Create a new FieldData object
/// </summary>
/// <param name="name">The name of the field</param>
/// <param name="typeIn">The AssemblyQualifiedName of the Field's data type</param>
/// <param name="spec">The unit type of the Field (set to UT_Undefined for non-floating point types</param>
public FieldData(string name, string typeIn, string spec) : this(name, typeIn, spec, null)
{
}
/// <summary>
/// Create a new FieldData object
/// </summary>
/// <param name="name">The name of the field</param>
/// <param name="typeIn">The AssemblyQualifiedName of the Field's data type</param>
/// <param name="spec">The unit type of the Field (set to UT_Undefined for non-floating point types</param>
/// <param name="subSchema">The SchemaWrapper of the field's subSchema, if the field is of type "Entity"</param>
public FieldData(string name, string typeIn, string spec, SchemaWrapper subSchema)
{
m_Name = name;
m_Type = typeIn;
m_Spec = spec;
m_SubSchema = subSchema;
}
#endregion
#region Other helper functions
public override string ToString()
{
StringBuilder strBuilder = new StringBuilder();
strBuilder.Append(" Field: ");
strBuilder.Append(Name);
strBuilder.Append(", ");
strBuilder.Append(Type);
strBuilder.Append(", ");
strBuilder.Append(Spec);
if (SubSchema != null)
{
strBuilder.Append(Environment.NewLine + " " + SubSchema.ToString());
}
return strBuilder.ToString();
}
#endregion
#region Properties
/// <summary>
/// The name of a schema field
/// </summary>
public string Name
{
get { return m_Name; }
set { m_Name = value; }
}
/// <summary>
/// The string representation of a schema field type (e.g. System.Int32)
/// </summary>
public string Type
{
get { return m_Type; }
set { m_Type = value; }
}
/// <summary>
/// The Unit type of the field
/// </summary>
public string Spec
{
get { return m_Spec; }
set { m_Spec = value; }
}
/// <summary>
/// The SchemaWrapper of the field's sub-Schema, if is of type "Entity"
/// </summary>
public SchemaWrapper SubSchema
{
get { return m_SubSchema; }
set { m_SubSchema = value; }
}
#endregion
#region Data
private SchemaWrapper m_SubSchema;
private string m_Name;
private string m_Type;
private string m_Spec;
#endregion
}
}
@@ -0,0 +1,36 @@
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("SchemaWrapperTools")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("Microsoft")]
[assembly: AssemblyProduct("SchemaWrapperTools")]
[assembly: AssemblyCopyright("Copyright © Microsoft 2010")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]
// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]
// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("b129ce81-2fb4-4183-9bec-403842cb32bc")]
// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("1.0.0.0")]
[assembly: AssemblyFileVersion("1.0.0.0")]
@@ -0,0 +1,194 @@
{\rtf1\adeflang1025\ansi\ansicpg1252\uc1\adeff0\deff0\stshfdbch31505\stshfloch31506\stshfhich31506\stshfbi0\deflang1033\deflangfe1033\themelang1033\themelangfe0\themelangcs0{\fonttbl{\f0\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f1\fbidi \fswiss\fcharset0\fprq2{\*\panose 020b0604020202020204}Arial;}
{\f2\fbidi \fmodern\fcharset0\fprq1{\*\panose 02070309020205020404}Courier New;}{\f3\fbidi \froman\fcharset2\fprq2{\*\panose 05050102010706020507}Symbol;}{\f10\fbidi \fnil\fcharset2\fprq2{\*\panose 05000000000000000000}Wingdings;}
{\f34\fbidi \froman\fcharset0\fprq2{\*\panose 02040503050406030204}Cambria Math;}{\f37\fbidi \fswiss\fcharset0\fprq2{\*\panose 020f0502020204030204}Calibri;}{\flomajor\f31500\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}
{\fdbmajor\f31501\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\fhimajor\f31502\fbidi \froman\fcharset0\fprq2{\*\panose 02040503050406030204}Cambria;}
{\fbimajor\f31503\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\flominor\f31504\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}
{\fdbminor\f31505\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\fhiminor\f31506\fbidi \fswiss\fcharset0\fprq2{\*\panose 020f0502020204030204}Calibri;}
{\fbiminor\f31507\fbidi \froman\fcharset0\fprq2{\*\panose 02020603050405020304}Times New Roman;}{\f332\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\f333\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}
{\f335\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\f336\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\f337\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\f338\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}
{\f339\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\f340\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\f342\fbidi \fswiss\fcharset238\fprq2 Arial CE;}{\f343\fbidi \fswiss\fcharset204\fprq2 Arial Cyr;}
{\f345\fbidi \fswiss\fcharset161\fprq2 Arial Greek;}{\f346\fbidi \fswiss\fcharset162\fprq2 Arial Tur;}{\f347\fbidi \fswiss\fcharset177\fprq2 Arial (Hebrew);}{\f348\fbidi \fswiss\fcharset178\fprq2 Arial (Arabic);}
{\f349\fbidi \fswiss\fcharset186\fprq2 Arial Baltic;}{\f350\fbidi \fswiss\fcharset163\fprq2 Arial (Vietnamese);}{\f352\fbidi \fmodern\fcharset238\fprq1 Courier New CE;}{\f353\fbidi \fmodern\fcharset204\fprq1 Courier New Cyr;}
{\f355\fbidi \fmodern\fcharset161\fprq1 Courier New Greek;}{\f356\fbidi \fmodern\fcharset162\fprq1 Courier New Tur;}{\f357\fbidi \fmodern\fcharset177\fprq1 Courier New (Hebrew);}{\f358\fbidi \fmodern\fcharset178\fprq1 Courier New (Arabic);}
{\f359\fbidi \fmodern\fcharset186\fprq1 Courier New Baltic;}{\f360\fbidi \fmodern\fcharset163\fprq1 Courier New (Vietnamese);}{\f672\fbidi \froman\fcharset238\fprq2 Cambria Math CE;}{\f673\fbidi \froman\fcharset204\fprq2 Cambria Math Cyr;}
{\f675\fbidi \froman\fcharset161\fprq2 Cambria Math Greek;}{\f676\fbidi \froman\fcharset162\fprq2 Cambria Math Tur;}{\f679\fbidi \froman\fcharset186\fprq2 Cambria Math Baltic;}{\f680\fbidi \froman\fcharset163\fprq2 Cambria Math (Vietnamese);}
{\f702\fbidi \fswiss\fcharset238\fprq2 Calibri CE;}{\f703\fbidi \fswiss\fcharset204\fprq2 Calibri Cyr;}{\f705\fbidi \fswiss\fcharset161\fprq2 Calibri Greek;}{\f706\fbidi \fswiss\fcharset162\fprq2 Calibri Tur;}
{\f709\fbidi \fswiss\fcharset186\fprq2 Calibri Baltic;}{\f710\fbidi \fswiss\fcharset163\fprq2 Calibri (Vietnamese);}{\flomajor\f31508\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}
{\flomajor\f31509\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\flomajor\f31511\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\flomajor\f31512\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}
{\flomajor\f31513\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\flomajor\f31514\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\flomajor\f31515\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}
{\flomajor\f31516\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\fdbmajor\f31518\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\fdbmajor\f31519\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}
{\fdbmajor\f31521\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\fdbmajor\f31522\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\fdbmajor\f31523\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}
{\fdbmajor\f31524\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\fdbmajor\f31525\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\fdbmajor\f31526\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}
{\fhimajor\f31528\fbidi \froman\fcharset238\fprq2 Cambria CE;}{\fhimajor\f31529\fbidi \froman\fcharset204\fprq2 Cambria Cyr;}{\fhimajor\f31531\fbidi \froman\fcharset161\fprq2 Cambria Greek;}{\fhimajor\f31532\fbidi \froman\fcharset162\fprq2 Cambria Tur;}
{\fhimajor\f31535\fbidi \froman\fcharset186\fprq2 Cambria Baltic;}{\fhimajor\f31536\fbidi \froman\fcharset163\fprq2 Cambria (Vietnamese);}{\fbimajor\f31538\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}
{\fbimajor\f31539\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\fbimajor\f31541\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\fbimajor\f31542\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}
{\fbimajor\f31543\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\fbimajor\f31544\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\fbimajor\f31545\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}
{\fbimajor\f31546\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\flominor\f31548\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\flominor\f31549\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}
{\flominor\f31551\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\flominor\f31552\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\flominor\f31553\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}
{\flominor\f31554\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\flominor\f31555\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\flominor\f31556\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}
{\fdbminor\f31558\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}{\fdbminor\f31559\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\fdbminor\f31561\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}
{\fdbminor\f31562\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}{\fdbminor\f31563\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\fdbminor\f31564\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}
{\fdbminor\f31565\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}{\fdbminor\f31566\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}{\fhiminor\f31568\fbidi \fswiss\fcharset238\fprq2 Calibri CE;}
{\fhiminor\f31569\fbidi \fswiss\fcharset204\fprq2 Calibri Cyr;}{\fhiminor\f31571\fbidi \fswiss\fcharset161\fprq2 Calibri Greek;}{\fhiminor\f31572\fbidi \fswiss\fcharset162\fprq2 Calibri Tur;}
{\fhiminor\f31575\fbidi \fswiss\fcharset186\fprq2 Calibri Baltic;}{\fhiminor\f31576\fbidi \fswiss\fcharset163\fprq2 Calibri (Vietnamese);}{\fbiminor\f31578\fbidi \froman\fcharset238\fprq2 Times New Roman CE;}
{\fbiminor\f31579\fbidi \froman\fcharset204\fprq2 Times New Roman Cyr;}{\fbiminor\f31581\fbidi \froman\fcharset161\fprq2 Times New Roman Greek;}{\fbiminor\f31582\fbidi \froman\fcharset162\fprq2 Times New Roman Tur;}
{\fbiminor\f31583\fbidi \froman\fcharset177\fprq2 Times New Roman (Hebrew);}{\fbiminor\f31584\fbidi \froman\fcharset178\fprq2 Times New Roman (Arabic);}{\fbiminor\f31585\fbidi \froman\fcharset186\fprq2 Times New Roman Baltic;}
{\fbiminor\f31586\fbidi \froman\fcharset163\fprq2 Times New Roman (Vietnamese);}}{\colortbl;\red0\green0\blue0;\red0\green0\blue255;\red0\green255\blue255;\red0\green255\blue0;\red255\green0\blue255;\red255\green0\blue0;\red255\green255\blue0;
\red255\green255\blue255;\red0\green0\blue128;\red0\green128\blue128;\red0\green128\blue0;\red128\green0\blue128;\red128\green0\blue0;\red128\green128\blue0;\red128\green128\blue128;\red192\green192\blue192;}{\*\defchp
\fs22\loch\af31506\hich\af31506\dbch\af31505 }{\*\defpap \ql \li0\ri0\sa200\sl276\slmult1\widctlpar\wrapdefault\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 }\noqfpromote {\stylesheet{\ql \li0\ri0\sa200\sl276\slmult1
\widctlpar\wrapdefault\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \rtlch\fcs1 \af0\afs22\alang1025 \ltrch\fcs0 \fs22\lang1033\langfe1033\loch\f31506\hich\af31506\dbch\af31505\cgrid\langnp1033\langfenp1033 \snext0 \sqformat \spriority0 Normal;}{\*
\cs10 \additive \ssemihidden \sunhideused \spriority1 Default Paragraph Font;}{\*
\ts11\tsrowd\trftsWidthB3\trpaddl108\trpaddr108\trpaddfl3\trpaddft3\trpaddfb3\trpaddfr3\tblind0\tblindtype3\tsvertalt\tsbrdrt\tsbrdrl\tsbrdrb\tsbrdrr\tsbrdrdgl\tsbrdrdgr\tsbrdrh\tsbrdrv \ql \li0\ri0\sa200\sl276\slmult1
\widctlpar\wrapdefault\aspalpha\aspnum\faauto\adjustright\rin0\lin0\itap0 \rtlch\fcs1 \af0\afs22\alang1025 \ltrch\fcs0 \fs22\lang1033\langfe1033\loch\f31506\hich\af31506\dbch\af31505\cgrid\langnp1033\langfenp1033 \snext11 \ssemihidden \sunhideused
Normal Table;}}{\*\listtable{\list\listtemplateid-889555842\listhybrid{\listlevel\levelnfc0\levelnfcn0\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace0\levelindent0{\leveltext\leveltemplateid2035172364\'02\'00);}{\levelnumbers\'01;}\rtlch\fcs1
\af0 \ltrch\fcs0 \fbias0 \fi-360\li1200\lin1200 }{\listlevel\levelnfc4\levelnfcn4\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext\leveltemplateid67698713\'02\'01.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0
\ltrch\fcs0 \fi-360\li1920\lin1920 }{\listlevel\levelnfc2\levelnfcn2\leveljc2\leveljcn2\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext\leveltemplateid67698715\'02\'02.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0
\fi-180\li2640\lin2640 }{\listlevel\levelnfc0\levelnfcn0\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext\leveltemplateid67698703\'02\'03.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0
\fi-360\li3360\lin3360 }{\listlevel\levelnfc4\levelnfcn4\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext\leveltemplateid67698713\'02\'04.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0
\fi-360\li4080\lin4080 }{\listlevel\levelnfc2\levelnfcn2\leveljc2\leveljcn2\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext\leveltemplateid67698715\'02\'05.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0
\fi-180\li4800\lin4800 }{\listlevel\levelnfc0\levelnfcn0\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext\leveltemplateid67698703\'02\'06.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0
\fi-360\li5520\lin5520 }{\listlevel\levelnfc4\levelnfcn4\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext\leveltemplateid67698713\'02\'07.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0
\fi-360\li6240\lin6240 }{\listlevel\levelnfc2\levelnfcn2\leveljc2\leveljcn2\levelfollow0\levelstartat1\lvltentative\levelspace0\levelindent0{\leveltext\leveltemplateid67698715\'02\'08.;}{\levelnumbers\'01;}\rtlch\fcs1 \af0 \ltrch\fcs0
\fi-180\li6960\lin6960 }{\listname ;}\listid370811281}{\list\listtemplateid-1850317920\listhybrid{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace360\levelindent0{\leveltext\leveltemplateid67698689
\'01\u-3913 ?;}{\levelnumbers;}\f3\fbias0 \fi-360\li720\lin720 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace360\levelindent0{\leveltext\leveltemplateid67698691\'01o;}{\levelnumbers;}\f2\fbias0
\fi-360\li1440\lin1440 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace360\levelindent0{\leveltext\leveltemplateid67698693\'01\u-3929 ?;}{\levelnumbers;}\f10\fbias0 \fi-360\li2160\lin2160 }{\listlevel\levelnfc23
\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0{\leveltext\leveltemplateid67698689\'01\u-3913 ?;}{\levelnumbers;}\f3\fbias0 \fi-360\li2880\lin2880 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0
\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0{\leveltext\leveltemplateid67698691\'01o;}{\levelnumbers;}\f2\fbias0 \fi-360\li3600\lin3600 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative
\levelspace360\levelindent0{\leveltext\leveltemplateid67698693\'01\u-3929 ?;}{\levelnumbers;}\f10\fbias0 \fi-360\li4320\lin4320 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0
{\leveltext\leveltemplateid67698689\'01\u-3913 ?;}{\levelnumbers;}\f3\fbias0 \fi-360\li5040\lin5040 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0{\leveltext
\leveltemplateid67698691\'01o;}{\levelnumbers;}\f2\fbias0 \fi-360\li5760\lin5760 }{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\lvltentative\levelspace360\levelindent0{\leveltext\leveltemplateid67698693
\'01\u-3929 ?;}{\levelnumbers;}\f10\fbias0 \fi-360\li6480\lin6480 }{\listname ;}\listid499009686}}{\*\listoverridetable{\listoverride\listid499009686\listoverridecount0\ls1}{\listoverride\listid370811281\listoverridecount0\ls2}}{\*\rsidtbl \rsid141089
\rsid727263\rsid1384628\rsid1643735\rsid2694459\rsid2706698\rsid3675435\rsid5207864\rsid5965259\rsid6188422\rsid7343557\rsid7606740\rsid7622664\rsid8523953\rsid9256058\rsid9325637\rsid9401674\rsid10321559\rsid10702366\rsid11365877\rsid12857485
\rsid13661538\rsid14306083\rsid14842436\rsid15232447\rsid15949907\rsid16518296}{\mmathPr\mmathFont34\mbrkBin0\mbrkBinSub0\msmallFrac0\mdispDef1\mlMargin0\mrMargin0\mdefJc1\mwrapIndent1440\mintLim0\mnaryLim1}{\info{\author Steven Mycynek}
{\operator Steven Mycynek}{\creatim\yr2010\mo12\dy20\hr12\min6}{\revtim\yr2011\mo1\dy11\hr12\min14}{\version18}{\edmins73}{\nofpages1}{\nofwords57}{\nofchars328}{\*\company Autodesk, Inc.}{\nofcharsws384}{\vern49255}}{\*\xmlnstbl {\xmlns1 http://schemas.m
icrosoft.com/office/word/2003/wordml}}\paperw12240\paperh15840\margl1440\margr1440\margt1440\margb1440\gutter0\ltrsect
\deftab420\widowctrl\ftnbj\aenddoc\trackmoves0\trackformatting1\donotembedsysfont0\relyonvml0\donotembedlingdata1\grfdocevents0\validatexml0\showplaceholdtext0\ignoremixedcontent0\saveinvalidxml0\showxmlerrors0\horzdoc\dghspace120\dgvspace120
\dghorigin1701\dgvorigin1984\dghshow0\dgvshow3\jcompress\ksulang1041\viewkind1\viewscale100\rsidroot2706698 {\*\fchars !),.:\'3b?D]\'7d}{\*\lchars ([\'7b}\fet0{\*\wgrffmtfilter 2450}\ilfomacatclnup0\ltrpar \sectd \ltrsect\linex0\sectdefaultcl\sftnbj
{\*\pnseclvl1\pnucrm\pnstart1\pnindent720\pnhang {\pntxta .}}{\*\pnseclvl2\pnucltr\pnstart1\pnindent720\pnhang {\pntxta .}}{\*\pnseclvl3\pndec\pnstart1\pnindent720\pnhang {\pntxta .}}{\*\pnseclvl4\pnlcltr\pnstart1\pnindent720\pnhang {\pntxta )}}
{\*\pnseclvl5\pndec\pnstart1\pnindent720\pnhang {\pntxtb (}{\pntxta )}}{\*\pnseclvl6\pnlcltr\pnstart1\pnindent720\pnhang {\pntxtb (}{\pntxta )}}{\*\pnseclvl7\pnlcrm\pnstart1\pnindent720\pnhang {\pntxtb (}{\pntxta )}}{\*\pnseclvl8
\pnlcltr\pnstart1\pnindent720\pnhang {\pntxtb (}{\pntxta )}}{\*\pnseclvl9\pnlcrm\pnstart1\pnindent720\pnhang {\pntxtb (}{\pntxta )}}\pard\plain \ltrpar\ql \li0\ri0\nowidctlpar\wrapdefault\faauto\rin0\lin0\itap0\pararsid13661538 \rtlch\fcs1
\af0\afs22\alang1025 \ltrch\fcs0 \fs22\lang1033\langfe1033\loch\af31506\hich\af31506\dbch\af31505\cgrid\langnp1033\langfenp1033 {\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 Application:}{\rtlch\fcs1
\af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 }{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 SchemaWrapper}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \line }
{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 Revit Platform:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 All\line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0
\b\f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 Revit Version:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 201\hich\af1\dbch\af31505\loch\f1 2.0\line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0
\b\f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 First Released For:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 2012.0\line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid11365877
\hich\af1\dbch\af31505\loch\f1 Programming Language:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 \hich\af1\dbch\af31505\loch\f1 C#\line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid11365877
\hich\af1\dbch\af31505\loch\f1 Skill Level:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 \hich\af1\dbch\af31505\loch\f1 Advanced\line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid11365877
\hich\af1\dbch\af31505\loch\f1 Category:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 \hich\af1\dbch\af31505\loch\f1 Elements\line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid11365877
\hich\af1\dbch\af31505\loch\f1 Type:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 \hich\af1\dbch\af31505\loch\f1 Application and \hich\af1\dbch\af31505\loch\f1 External\hich\af1\dbch\af31505\loch\f1
\hich\af1\dbch\af31505\loch\f1 Command\line \line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 Subject:}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1
\hich\af1\dbch\af31505\loch\f1 Create, read, update, and delete third party extensible storage in Revit Elements.\line }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid11365877 \hich\af1\dbch\af31505\loch\f1 Summary:}{\rtlch\fcs1 \ab\af1\afs20
\ltrch\fcs0 \b\f1\fs20\insrsid11365877
\par
\par }{\rtlch\fcs1 \ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid7622664 \hich\af1\dbch\af31505\loch\f1 Please see ../../ExtensibleStorageManager/CS}{\rtlch\fcs1 \af0 \ltrch\fcs0 \insrsid7622664 \hich\af31506\dbch\af31505\loch\f31506 /}{\rtlch\fcs1
\ab\af1\afs20 \ltrch\fcs0 \b\f1\fs20\insrsid7622664\charrsid7622664 \hich\af1\dbch\af31505\loch\f1 ReadMe_ExtensibleStorageManager.rtf}{\rtlch\fcs1 \af1\afs20 \ltrch\fcs0 \f1\fs20\insrsid9325637\charrsid14306083
\par }{\*\themedata 504b030414000600080000002100e9de0fbfff0000001c020000130000005b436f6e74656e745f54797065735d2e786d6cac91cb4ec3301045f748fc83e52d4a
9cb2400825e982c78ec7a27cc0c8992416c9d8b2a755fbf74cd25442a820166c2cd933f79e3be372bd1f07b5c3989ca74aaff2422b24eb1b475da5df374fd9ad
5689811a183c61a50f98f4babebc2837878049899a52a57be670674cb23d8e90721f90a4d2fa3802cb35762680fd800ecd7551dc18eb899138e3c943d7e503b6
b01d583deee5f99824e290b4ba3f364eac4a430883b3c092d4eca8f946c916422ecab927f52ea42b89a1cd59c254f919b0e85e6535d135a8de20f20b8c12c3b0
0c895fcf6720192de6bf3b9e89ecdbd6596cbcdd8eb28e7c365ecc4ec1ff1460f53fe813d3cc7f5b7f020000ffff0300504b030414000600080000002100a5d6
a7e7c0000000360100000b0000005f72656c732f2e72656c73848fcf6ac3300c87ef85bd83d17d51d2c31825762fa590432fa37d00e1287f68221bdb1bebdb4f
c7060abb0884a4eff7a93dfeae8bf9e194e720169aaa06c3e2433fcb68e1763dbf7f82c985a4a725085b787086a37bdbb55fbc50d1a33ccd311ba548b6309512
0f88d94fbc52ae4264d1c910d24a45db3462247fa791715fd71f989e19e0364cd3f51652d73760ae8fa8c9ffb3c330cc9e4fc17faf2ce545046e37944c69e462
a1a82fe353bd90a865aad41ed0b5b8f9d6fd010000ffff0300504b0304140006000800000021006b799616830000008a0000001c0000007468656d652f746865
6d652f7468656d654d616e616765722e786d6c0ccc4d0ac3201040e17da17790d93763bb284562b2cbaebbf600439c1a41c7a0d29fdbd7e5e38337cedf14d59b
4b0d592c9c070d8a65cd2e88b7f07c2ca71ba8da481cc52c6ce1c715e6e97818c9b48d13df49c873517d23d59085adb5dd20d6b52bd521ef2cdd5eb9246a3d8b
4757e8d3f729e245eb2b260a0238fd010000ffff0300504b03041400060008000000210030dd4329a8060000a41b0000160000007468656d652f7468656d652f
7468656d65312e786d6cec594f6fdb3614bf0fd87720746f6327761a07758ad8b19b2d4d1bc46e871e698996d850a240d2497d1bdae38001c3ba618715d86d87
615b8116d8a5fb34d93a6c1dd0afb0475292c5585e9236d88aad3e2412f9e3fbff1e1fa9abd7eec70c1d1221294fda5efd72cd4324f1794093b0eddd1ef62fad
79482a9c0498f184b4bd2991deb58df7dfbb8ad755446282607d22d771db8b944ad79796a40fc3585ee62949606ecc458c15bc8a702910f808e8c66c69b9565b
5d8a314d3c94e018c8de1a8fa94fd05093f43672e23d06af89927ac06762a049136785c10607758d9053d965021d62d6f6804fc08f86e4bef210c352c144dbab
999fb7b4717509af678b985ab0b6b4ae6f7ed9ba6c4170b06c788a705430adf71bad2b5b057d03606a1ed7ebf5babd7a41cf00b0ef83a6569632cd467faddec9
699640f6719e76b7d6ac355c7c89feca9cccad4ea7d36c65b258a206641f1b73f8b5da6a6373d9c11b90c537e7f08dce66b7bbeae00dc8e257e7f0fd2badd586
8b37a088d1e4600ead1ddaef67d40bc898b3ed4af81ac0d76a197c86826828a24bb318f3442d8ab518dfe3a20f000d6458d104a9694ac6d88728eee2782428d6
0cf03ac1a5193be4cbb921cd0b495fd054b5bd0f530c1931a3f7eaf9f7af9e3f45c70f9e1d3ff8e9f8e1c3e3073f5a42ceaa6d9c84e5552fbffdeccfc71fa33f
9e7ef3f2d117d57859c6fffac327bffcfc793510d26726ce8b2f9ffcf6ecc98baf3efdfdbb4715f04d814765f890c644a29be408edf3181433567125272371be
15c308d3f28acd249438c19a4b05fd9e8a1cf4cd296699771c393ac4b5e01d01e5a30a787d72cf1178108989a2159c77a2d801ee72ce3a5c545a6147f32a9979
3849c26ae66252c6ed637c58c5bb8b13c7bfbd490a75330f4b47f16e441c31f7184e140e494214d273fc80900aedee52ead87597fa824b3e56e82e451d4c2b4d
32a423279a668bb6690c7e9956e90cfe766cb37b077538abd27a8b1cba48c80acc2a841f12e698f13a9e281c57911ce298950d7e03aba84ac8c154f8655c4f2a
f074481847bd804859b5e696007d4b4edfc150b12addbecba6b18b148a1e54d1bc81392f23b7f84137c2715a851dd0242a633f900710a218ed715505dfe56e86
e877f0034e16bafb0e258ebb4faf06b769e888340b103d331115bebc4eb813bf83291b63624a0d1475a756c734f9bbc2cd28546ecbe1e20a3794ca175f3fae90
fb6d2dd99bb07b55e5ccf68942bd0877b23c77b908e8db5f9db7f024d9239010f35bd4bbe2fcae387bfff9e2bc289f2fbe24cfaa301468dd8bd846dbb4ddf1c2
ae7b4c191ba8292337a469bc25ec3d411f06f53a73e224c5292c8de0516732307070a1c0660d125c7d44553488700a4d7bddd3444299910e254ab984c3a219ae
a4adf1d0f82b7bd46cea4388ad1c12ab5d1ed8e1153d9c9f350a3246aad01c6873462b9ac05999ad5cc988826eafc3acae853a33b7ba11cd1445875ba1b236b1
399483c90bd560b0b0263435085a21b0f22a9cf9356b38ec6046026d77eba3dc2dc60b17e92219e180643ed27acffba86e9c94c7ca9c225a0f1b0cfae0788ad5
4adc5a9aec1b703b8b93caec1a0bd8e5de7b132fe5113cf312503b998e2c2927274bd051db6b35979b1ef271daf6c6704e86c73805af4bdd476216c26593af84
0dfb5393d964f9cc9bad5c313709ea70f561ed3ea7b053075221d51696910d0d339585004b34272bff7213cc7a510a5454a3b349b1b206c1f0af490176745d4b
c663e2abb2b34b23da76f6352ba57ca2881844c1111ab189d8c7e07e1daaa04f40255c77988aa05fe06e4e5bdb4cb9c5394bbaf28d98c1d971ccd20867e556a7
689ec9166e0a522183792b8907ba55ca6e943bbf2a26e52f48957218ffcf54d1fb09dc3eac04da033e5c0d0b8c74a6b43d2e54c4a10aa511f5fb021a07533b20
5ae07e17a621a8e082dafc17e450ffb739676998b48643a4daa7211214f623150942f6a02c99e83b85583ddbbb2c4996113211551257a656ec1139246ca86be0
aadedb3d1441a89b6a929501833b197fee7b9641a3503739e57c732a59b1f7da1cf8a73b1f9bcca0945b874d4393dbbf10b1680f66bbaa5d6f96e77b6f59113d
316bb31a795600b3d256d0cad2fe354538e7566b2bd69cc6cbcd5c38f0e2bcc63058344429dc2121fd07f63f2a7c66bf76e80d75c8f7a1b622f878a18941d840
545fb28d07d205d20e8ea071b283369834296bdaac75d256cb37eb0bee740bbe278cad253b8bbfcf69eca23973d939b97891c6ce2cecd8da8e2d343578f6648a
c2d0383fc818c798cf64e52f597c740f1cbd05df0c264c49134cf09d4a60e8a107260f20f92d47b374e32f000000ffff0300504b030414000600080000002100
0dd1909fb60000001b010000270000007468656d652f7468656d652f5f72656c732f7468656d654d616e616765722e786d6c2e72656c73848f4d0ac2301484f7
8277086f6fd3ba109126dd88d0add40384e4350d363f2451eced0dae2c082e8761be9969bb979dc9136332de3168aa1a083ae995719ac16db8ec8e4052164e89
d93b64b060828e6f37ed1567914b284d262452282e3198720e274a939cd08a54f980ae38a38f56e422a3a641c8bbd048f7757da0f19b017cc524bd62107bd500
1996509affb3fd381a89672f1f165dfe514173d9850528a2c6cce0239baa4c04ca5bbabac4df000000ffff0300504b01022d0014000600080000002100e9de0f
bfff0000001c0200001300000000000000000000000000000000005b436f6e74656e745f54797065735d2e786d6c504b01022d0014000600080000002100a5d6
a7e7c0000000360100000b00000000000000000000000000300100005f72656c732f2e72656c73504b01022d00140006000800000021006b799616830000008a
0000001c00000000000000000000000000190200007468656d652f7468656d652f7468656d654d616e616765722e786d6c504b01022d00140006000800000021
0030dd4329a8060000a41b00001600000000000000000000000000d60200007468656d652f7468656d652f7468656d65312e786d6c504b01022d001400060008
00000021000dd1909fb60000001b0100002700000000000000000000000000b20900007468656d652f7468656d652f5f72656c732f7468656d654d616e616765722e786d6c2e72656c73504b050600000000050005005d010000ad0a00000000}
{\*\colorschememapping 3c3f786d6c2076657273696f6e3d22312e302220656e636f64696e673d225554462d3822207374616e64616c6f6e653d22796573223f3e0d0a3c613a636c724d
617020786d6c6e733a613d22687474703a2f2f736368656d61732e6f70656e786d6c666f726d6174732e6f72672f64726177696e676d6c2f323030362f6d6169
6e22206267313d226c743122207478313d22646b3122206267323d226c743222207478323d22646b322220616363656e74313d22616363656e74312220616363
656e74323d22616363656e74322220616363656e74333d22616363656e74332220616363656e74343d22616363656e74342220616363656e74353d22616363656e74352220616363656e74363d22616363656e74362220686c696e6b3d22686c696e6b2220666f6c486c696e6b3d22666f6c486c696e6b222f3e}
{\*\latentstyles\lsdstimax267\lsdlockeddef0\lsdsemihiddendef1\lsdunhideuseddef1\lsdqformatdef0\lsdprioritydef99{\lsdlockedexcept \lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority0 \lsdlocked0 Normal;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority9 \lsdlocked0 heading 1;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 2;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 3;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 4;
\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 5;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 6;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 7;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 8;\lsdqformat1 \lsdpriority9 \lsdlocked0 heading 9;
\lsdpriority39 \lsdlocked0 toc 1;\lsdpriority39 \lsdlocked0 toc 2;\lsdpriority39 \lsdlocked0 toc 3;\lsdpriority39 \lsdlocked0 toc 4;\lsdpriority39 \lsdlocked0 toc 5;\lsdpriority39 \lsdlocked0 toc 6;\lsdpriority39 \lsdlocked0 toc 7;
\lsdpriority39 \lsdlocked0 toc 8;\lsdpriority39 \lsdlocked0 toc 9;\lsdqformat1 \lsdpriority35 \lsdlocked0 caption;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority10 \lsdlocked0 Title;\lsdpriority1 \lsdlocked0 Default Paragraph Font;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority11 \lsdlocked0 Subtitle;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority22 \lsdlocked0 Strong;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority20 \lsdlocked0 Emphasis;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority59 \lsdlocked0 Table Grid;\lsdunhideused0 \lsdlocked0 Placeholder Text;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority1 \lsdlocked0 No Spacing;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading;\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List;\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List;\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List;\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid;\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 1;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 1;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 1;\lsdunhideused0 \lsdlocked0 Revision;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority34 \lsdlocked0 List Paragraph;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority29 \lsdlocked0 Quote;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority30 \lsdlocked0 Intense Quote;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 1;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 1;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 1;\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 2;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 2;\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 3;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 3;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 3;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 3;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 3;\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 3;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 4;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 4;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 4;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 4;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 4;\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 5;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 5;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 5;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 5;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 5;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 5;\lsdsemihidden0 \lsdunhideused0 \lsdpriority60 \lsdlocked0 Light Shading Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority61 \lsdlocked0 Light List Accent 6;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority62 \lsdlocked0 Light Grid Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority63 \lsdlocked0 Medium Shading 1 Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority64 \lsdlocked0 Medium Shading 2 Accent 6;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority65 \lsdlocked0 Medium List 1 Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority66 \lsdlocked0 Medium List 2 Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority67 \lsdlocked0 Medium Grid 1 Accent 6;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority68 \lsdlocked0 Medium Grid 2 Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority69 \lsdlocked0 Medium Grid 3 Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority70 \lsdlocked0 Dark List Accent 6;
\lsdsemihidden0 \lsdunhideused0 \lsdpriority71 \lsdlocked0 Colorful Shading Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority72 \lsdlocked0 Colorful List Accent 6;\lsdsemihidden0 \lsdunhideused0 \lsdpriority73 \lsdlocked0 Colorful Grid Accent 6;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority19 \lsdlocked0 Subtle Emphasis;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority21 \lsdlocked0 Intense Emphasis;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority31 \lsdlocked0 Subtle Reference;\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority32 \lsdlocked0 Intense Reference;
\lsdsemihidden0 \lsdunhideused0 \lsdqformat1 \lsdpriority33 \lsdlocked0 Book Title;\lsdpriority37 \lsdlocked0 Bibliography;\lsdqformat1 \lsdpriority39 \lsdlocked0 TOC Heading;}}{\*\datastore 010500000200000018000000
4d73786d6c322e534158584d4c5265616465722e362e3000000000000000000000060000
d0cf11e0a1b11ae1000000000000000000000000000000003e000300feff090006000000000000000000000001000000010000000000000000100000feffffff00000000feffffff0000000000000000ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
fffffffffffffffffdfffffffeffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffff
ffffffffffffffffffffffffffffffff52006f006f007400200045006e00740072007900000000000000000000000000000000000000000000000000000000000000000000000000000000000000000016000500ffffffffffffffffffffffff0c6ad98892f1d411a65f0040963251e50000000000000000000000001006
3afbb2b1cb01feffffff00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffff00000000000000000000000000000000000000000000000000000000
00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffff0000000000000000000000000000000000000000000000000000
000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000ffffffffffffffffffffffff000000000000000000000000000000000000000000000000
0000000000000000000000000000000000000000000000000105000000000000}}
@@ -0,0 +1,188 @@
//
// (C) Copyright 2003-2019 by Autodesk, Inc. All rights reserved.
//
// Permission to use, copy, modify, and distribute this software in
// object code form for any purpose and without fee is hereby granted
// provided that the above copyright notice appears in all copies and
// that both that copyright notice and the limited warranty and
// restricted rights notice below appear in all supporting
// documentation.
//
// AUTODESK PROVIDES THIS PROGRAM 'AS IS' AND WITH ALL ITS FAULTS.
// AUTODESK SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. AUTODESK, INC.
// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
// UNINTERRUPTED OR ERROR FREE.
//
// Use, duplication, or disclosure by the U.S. Government is subject to
// restrictions set forth in FAR 52.227-19 (Commercial Computer
// Software - Restricted Rights) and DFAR 252.227-7013(c)(1)(ii)
// (Rights in Technical Data and Computer Software), as applicable.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Autodesk.Revit.DB;
using Autodesk.Revit.UI;
using Autodesk.Revit.DB.ExtensibleStorage;
using System.Xml.Serialization;
using System.Runtime.Serialization;
using System.IO;
using System.ComponentModel;
namespace SchemaWrapperTools
{
/// <summary>
/// A class to store a list of FieldData objects as well as the top level data (name, access levels, SchemaId, etc..)
/// of an Autodesk.Revit.DB.ExtensibleStorage.Schema
/// </summary>
[Serializable]
public class SchemaDataWrapper
{
#region Constructors
/// <summary>
/// For serialization only -- Do not use.
/// </summary>
internal SchemaDataWrapper() { }
/// <summary>
/// Create a new SchemaDataWrapper
/// </summary>
/// <param name="schemaId">The Guid of the Schema</param>
/// <param name="readAccess">The access level for read permission</param>
/// <param name="writeAccess">The access level for write permission</param>
/// <param name="vendorId">The user-registered vendor ID string</param>
/// <param name="applicationId">The application ID from the application manifest</param>
/// <param name="name">The name of the schema</param>
/// <param name="documentation">Descriptive details on the schema</param>
public SchemaDataWrapper(Guid schemaId, AccessLevel readAccess, AccessLevel writeAccess, string vendorId, string applicationId, string name, string documentation)
{
DataList = new System.Collections.Generic.List<FieldData >();
SchemaId = schemaId.ToString();
ReadAccess = readAccess;
WriteAccess = writeAccess;
VendorId = vendorId;
ApplicationId = applicationId;
Name = name;
Documentation = documentation;
}
#endregion
#region Data addition
/// <summary>
/// Adds a new field to the wrapper's list of fields.
/// </summary>
/// <param name="name">the name of the field</param>
/// <param name="typeIn">the data type of the field</param>
/// <param name="spec">The unit type of the Field (set to UT_Undefined for non-floating point types</param>
/// <param name="subSchema">The SchemaWrapper of the field's subSchema, if the field is of type "Entity"</param>
public void AddData(string name, System.Type typeIn, ForgeTypeId spec, SchemaWrapper subSchema)
{
m_DataList.Add(new FieldData(name, typeIn.FullName, spec.TypeId, subSchema));
}
#endregion
#region Properties
/// <summary>
/// The list of FieldData objects in the wrapper
/// </summary>
public List<FieldData> DataList
{
get { return m_DataList; }
set { m_DataList = value; }
}
/// <summary>
/// The schemaId Guid of the Schema
/// </summary>
public string SchemaId
{
get { return m_schemaId; }
set { m_schemaId = value; }
}
/// <summary>
/// The read access of the Schema
/// </summary>
public AccessLevel ReadAccess
{
get { return m_ReadAccess; }
set { m_ReadAccess = value; }
}
/// <summary>
/// The write access of the Schema
/// </summary>
public AccessLevel WriteAccess
{
get { return m_WriteAccess; }
set { m_WriteAccess = value; }
}
/// <summary>
/// Vendor Id
/// </summary>
public string VendorId
{
get { return m_vendorId; }
set
{
m_vendorId = value;
}
}
/// <summary>
/// Application Id
/// </summary>
public string ApplicationId
{
get { return m_applicationId; }
set { m_applicationId = value; }
}
/// <summary>
/// The documentation string for the schema
/// </summary>
public string Documentation
{
get { return m_Documentation; }
set
{
m_Documentation = value;
}
}
/// <summary>
/// The name of the schema
/// </summary>
public string Name
{
get { return m_Name; }
set
{
m_Name = value;
}
}
#endregion
#region Data
private AccessLevel m_ReadAccess;
private AccessLevel m_WriteAccess;
private System.Collections.Generic.List<FieldData> m_DataList;
private string m_applicationId;
private string m_schemaId;
private string m_vendorId;
private string m_Name;
private string m_Documentation;
#endregion
}
}
@@ -0,0 +1,532 @@
//
// (C) Copyright 2003-2019 by Autodesk, Inc. All rights reserved.
//
// Permission to use, copy, modify, and distribute this software in
// object code form for any purpose and without fee is hereby granted
// provided that the above copyright notice appears in all copies and
// that both that copyright notice and the limited warranty and
// restricted rights notice below appear in all supporting
// documentation.
//
// AUTODESK PROVIDES THIS PROGRAM 'AS IS' AND WITH ALL ITS FAULTS.
// AUTODESK SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTY OF
// MERCHANTABILITY OR FITNESS FOR A PARTICULAR USE. AUTODESK, INC.
// DOES NOT WARRANT THAT THE OPERATION OF THE PROGRAM WILL BE
// UNINTERRUPTED OR ERROR FREE.
//
// Use, duplication, or disclosure by the U.S. Government is subject to
// restrictions set forth in FAR 52.227-19 (Commercial Computer
// Software - Restricted Rights) and DFAR 252.227-7013(c)(1)(ii)
// (Rights in Technical Data and Computer Software), as applicable.
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Autodesk.Revit.DB;
using Autodesk.Revit.UI;
using Autodesk.Revit.DB.ExtensibleStorage;
using System.Xml.Serialization;
using System.Runtime.Serialization;
using System.IO;
using System.Reflection;
using System.Diagnostics;
namespace SchemaWrapperTools
{
/// <summary>
/// This class provides a simpler level of access to the
/// Autodesk.Revit.DB.ExtensibleStorage Schema and SchemaBuilder objects
/// and also provides easy serialization of schema data to xml for the user.
/// </summary>
[Serializable]
public class SchemaWrapper
{
#region Constructors and class Factories
/// <summary>
/// For serialization only -- Do not use.
/// </summary>
internal SchemaWrapper() { }
/// <summary>
/// Creates a new SchemaWrapper from an existing schema.
/// </summary>
/// <param name="schema">A schema to create a wrapper from</param>
/// <returns>A new SchemaWrapper containing all data in the schema</returns>
public static SchemaWrapper FromSchema(Schema schema)
{
SchemaWrapper swReturn = new SchemaWrapper(schema);
foreach (Field currentField in schema.ListFields())
{
//We need to add call AddField on the SchemaWrapper we are creating for each field in the source schema.
//Since we do not know the data type of the field yet, we need to get the generic method first and
//then query the field data types from the field and instantiate a new generic method with those types as parameters.
//Get the "AddField" method.
MethodInfo addFieldmethod = typeof(SchemaWrapper).GetMethod("AddField", new Type[] { typeof(string), typeof(ForgeTypeId), typeof(SchemaWrapper) });
Type[] methodGenericParameters = null;
//Get the generic type parameters. The type will either be a single type, an IList<> of a single type, or an IDictionary<> of a key type and a value type.
if (currentField.ContainerType == ContainerType.Simple)
methodGenericParameters = new Type[] { currentField.ValueType };
else if (currentField.ContainerType == ContainerType.Array)
methodGenericParameters = new Type[] { typeof(IList<int>).GetGenericTypeDefinition().MakeGenericType(new Type[] { currentField.ValueType }) };
else
methodGenericParameters = new Type[] { typeof(Dictionary<int, int>).GetGenericTypeDefinition().MakeGenericType(new Type[] { currentField.KeyType, currentField.ValueType }) };
//Instantiate a new generic method from the "AddField" method we got before with the generic parameters we got
//from the current field we are querying.
MethodInfo genericAddFieldMethodInstantiated = addFieldmethod.MakeGenericMethod(methodGenericParameters);
SchemaWrapper swSub = null; //Our subSchema is null by default unless the field is of type "Entity," in which case
//we will call "FromSchema" again on the field's subSchema.
if (currentField.ValueType == typeof(Entity))
{
Schema subSchema = Schema.Lookup(currentField.SubSchemaGUID);
swSub = SchemaWrapper.FromSchema(subSchema);
}
//Invoke the "AddField" method with the generic parameters from the current field.
genericAddFieldMethodInstantiated.Invoke(swReturn, new object[] { currentField.FieldName, currentField.GetSpecTypeId(), swSub });
}
//Note that we don't call SchemaWrapper.FinishSchema here.
//The Autodesk.Revit.DB.ExtensibleStorage.Schema object already exists and is registered -- we're just populating the outer wrapper.
return swReturn;
}
/// <summary>
/// Creates a new SchemaWrapper from a Guid
/// </summary>
/// <param name="schemaId">The schemaId guid</param>
/// <returns>A new SchemaWrapper</returns>
public static SchemaWrapper NewSchema(Guid schemaId, AccessLevel readAccess, AccessLevel writeAccess, string vendorId, string applicationId, string name, string description)
{
return new SchemaWrapper(schemaId, readAccess, writeAccess, vendorId, applicationId, name, description);
}
/// <summary>
/// Creates a new SchemaWrapper from an XML file on disk
/// </summary>
/// <param name="xmlDataPath">The path to the XML file containing a schema definition</param>
/// <returns>A new SchemaWrapper</returns>
public static SchemaWrapper FromXml(string xmlDataPath)
{
XmlSerializer sampleSchemaInXml = new XmlSerializer(typeof(SchemaWrapper));
Stream streamXmlIn = new FileStream(xmlDataPath, FileMode.Open, FileAccess.Read, FileShare.Read);
SchemaWrapper wrapperIn = null;
try
{
wrapperIn = sampleSchemaInXml.Deserialize(streamXmlIn) as SchemaWrapper;
}
catch (Exception ex)
{
Debug.WriteLine("Could not deserialize schema file." + ex.ToString());
return null;
}
wrapperIn.SetRevitAssembly();
streamXmlIn.Close();
try
{
wrapperIn.FinishSchema();
}
catch (Exception ex)
{
Debug.WriteLine("Could not create schema." + ex.ToString());
return null;
}
return wrapperIn;
}
/// <summary>
/// Constructor used by class factories
/// </summary>
private SchemaWrapper(Guid schemaId, AccessLevel readAccess, AccessLevel writeAccess, string vendorId, string applicationId, string schemaName, string schemaDescription)
{
m_SchemaDataWrapper = new SchemaDataWrapper(schemaId, readAccess, writeAccess, vendorId, applicationId, schemaName, schemaDescription);
SetRevitAssembly();
}
private SchemaWrapper(Schema schema) : this(schema.GUID, schema.ReadAccessLevel, schema.WriteAccessLevel, schema.VendorId, schema.ApplicationGUID.ToString(), schema.SchemaName, schema.Documentation)
{
this.SetSchema(schema);
}
#endregion
#region Active schema manipulation
/// <summary>
/// Adds a new field to the SchemaWrapper
/// </summary>
/// <typeparam name="TypeName">Currently supported types: int, short, float, double, bool, string, ElementId, XYZ, UV, Guid, Entity, IDictionary<>, IList<>. IDictionary<> does not support floating point types, XYZ, UV, or Entity as Key parameters.</typeparam>
/// <param name="name">The name of the field</param>
/// <param name="spec">The unit type of the field. Defintion required for floating point, XYZ, and UV types</param>
/// <param name="subSchema">A subSchemaWrapper, if the field is of type Entity</param>
public void AddField<TypeName>(string name, ForgeTypeId spec, SchemaWrapper subSchema)
{
m_SchemaDataWrapper.AddData(name, typeof(TypeName), spec, subSchema);
}
/// <summary>
/// Create a new Autodesk.Revit.DB.ExtensibleStorage.SchemaBuilder and Schema from
/// the data in the SchemaWrapper.
/// </summary>
public void FinishSchema()
{
//Create the Autodesk.Revit.DB.ExtensibleStorage.SchemaBuilder that actually builds the schema
m_SchemaBuilder = new SchemaBuilder(new Guid(m_SchemaDataWrapper.SchemaId));
//We will add a new field to our schema from each FieldData object in our SchemaWrapper
foreach (FieldData currentFieldData in m_SchemaDataWrapper.DataList)
{
//If the current field's type is a supported system type (int, string, etc...),
//we can instantiate it with Type.GetType(). If the current field's type is a supported Revit API type
//(XYZ, elementID, etc...), we need to call GetType from the RevitAPI.dll assembly object.
Type fieldType = null;
try
{
fieldType = Type.GetType(currentFieldData.Type, true, true);
}
catch (Exception ex) //Get the type from the Revit API assembly if it is not a system type.
{
Debug.WriteLine(ex.ToString());
try
{
//Get the field from the Revit API assembly.
fieldType = m_Assembly.GetType(currentFieldData.Type);
}
catch (Exception exx)
{
Debug.WriteLine("Error getting type: " + exx.ToString());
throw;
}
}
//Now that we have the data type of field we need to add, we need to call either
//SchemaBuilder.AddSimpleField, AddArrayField, or AddMapField.
FieldBuilder currentFieldBuilder = null;
Guid subSchemaId = Guid.Empty;
Type[] genericParams = null;
if (currentFieldData.SubSchema != null)
subSchemaId = new Guid(currentFieldData.SubSchema.Data.SchemaId);
//If our data type is a generic, it is an IList<> or an IDictionary<>, so it's an array or map type
if (fieldType.IsGenericType)
{
Type tGeneric = fieldType.GetGenericTypeDefinition(); //tGeneric will be either an IList<> or an IDictionary<>.
//Create an IList<> or an IDictionary<> to compare against tGeneric.
Type iDictionaryType = typeof(IDictionary<int, int>).GetGenericTypeDefinition();
Type iListType = typeof(IList<int>).GetGenericTypeDefinition();
genericParams = fieldType.GetGenericArguments(); //Get the actual data type(s) stored in the field's IList<> or IDictionary<>
if (tGeneric == iDictionaryType)
//Pass the key and value type of our dictionary type to AddMapField.
currentFieldBuilder = m_SchemaBuilder.AddMapField(currentFieldData.Name, genericParams[0], genericParams[1]);
else if (tGeneric == iListType)
//Pass the value type of our list type to AddArrayField.
currentFieldBuilder = m_SchemaBuilder.AddArrayField(currentFieldData.Name, genericParams[0]);
else
throw new Exception("Generic type is neither IList<> nor IDictionary<>, cannot process.");
}
else
//The simpler case -- just add field using a name and a System.Type.
currentFieldBuilder = m_SchemaBuilder.AddSimpleField(currentFieldData.Name, fieldType);
if ( //if we're dealing with an Entity as a simple field, map field, or list field and need to do recursion...
(fieldType == (typeof(Entity)))
||
(fieldType.IsGenericType && ((genericParams[0] == (typeof(Entity))) || ((genericParams.Length > 1) && (genericParams[1] == typeof(Entity)))))
)
{
currentFieldBuilder.SetSubSchemaGUID(subSchemaId); //Set the SubSchemaID if our field
currentFieldData.SubSchema.FinishSchema(); //Recursively create the schema for the subSchema.
}
if (!string.IsNullOrEmpty(currentFieldData.Spec))
currentFieldBuilder.SetSpec(new ForgeTypeId(currentFieldData.Spec));
}
//Set all the top level data in the schema we are generating.
m_SchemaBuilder.SetReadAccessLevel(this.Data.ReadAccess);
m_SchemaBuilder.SetWriteAccessLevel(this.Data.WriteAccess);
m_SchemaBuilder.SetVendorId(this.Data.VendorId);
m_SchemaBuilder.SetApplicationGUID(new Guid(this.Data.ApplicationId));
m_SchemaBuilder.SetDocumentation(this.Data.Documentation);
m_SchemaBuilder.SetSchemaName(this.Data.Name);
//Actually finish creating the Autodesk.Revit.DB.ExtensibleStorage.Schema.
m_Schema = m_SchemaBuilder.Finish();
}
/// <summary>
/// Serializes a SchemaWrapper to an Xml file.
/// </summary>
/// <param name="xmlDataPath">The path to save schema data</param>
public void ToXml(string xmlDataPath)
{
XmlSerializer sampleSchemaOutXml = new XmlSerializer(typeof(SchemaWrapper));
Stream streamXmlOut = new FileStream(xmlDataPath, FileMode.OpenOrCreate, FileAccess.ReadWrite, FileShare.ReadWrite);
sampleSchemaOutXml.Serialize(streamXmlOut, this);
streamXmlOut.Close();
return;
}
public override string ToString()
{
StringBuilder strBuilder = new StringBuilder();
strBuilder.AppendLine("--Start Schema-- " + " Name: " + this.Data.Name + ", Description: " + this.Data.Documentation + ", Id: " + this.Data.SchemaId + ", ReadAccess: " + this.Data.ReadAccess.ToString() + ", WriteAccess: " + this.Data.WriteAccess.ToString());
foreach (FieldData fd in this.Data.DataList)
{
strBuilder.AppendLine(fd.ToString());
}
strBuilder.AppendLine("--End Schema--");
return strBuilder.ToString();
}
#endregion
#region Helper Methods
/// <summary>
/// Returns a string representation of all data in an Entity
/// </summary>
/// <param name="entity">The entity to query</param>
/// <returns>All entity data as a string</returns>
public string GetSchemaEntityData(Entity entity)
{
StringBuilder swBuilder = new StringBuilder();
DumpAllSchemaEntityData<Entity>(entity, entity.Schema, swBuilder);
return swBuilder.ToString();
}
/// <summary>
/// Recursively gets all data from an Entity and appends it in string format to a StringBuilder.
/// </summary>
/// <typeparam name="EntityType">A type parameter that will always be set to type "Entity" -- used to get around some type reflection limitations in .NET</typeparam>
/// <param name="storageEntity">The entity to query</param>
/// <param name="schema">The schema of the Entity</param>
/// <param name="strBuilder">The StringBuilder to append entity data to</param>
private void DumpAllSchemaEntityData<EntityType>(EntityType storageEntity, Schema schema, StringBuilder strBuilder)
{
strBuilder.AppendLine("Schema/Entity Name: " + "" + ", Description: " + schema.Documentation + ", Id: " + schema.GUID.ToString() + ", Read Access: " + schema.ReadAccessLevel.ToString() + ", Write Access: " + schema.WriteAccessLevel.ToString());
foreach (Field currentField in schema.ListFields())
{
//Here, we call GetFieldDataAsString on this class, the SchemaWrapper class. However, we must
//call it with specific generic parameters that are only known at runtime, so we must use reflection to
//dynamically create a method with parameters from the current field we want to extract data from
ParameterModifier[] pmodifiers = new ParameterModifier[0]; //a Dummy parameter needed for GetMethod() call, empty
//Get the method.
MethodInfo getFieldDataAsStringMethod = typeof(SchemaWrapper).GetMethod("GetFieldDataAsString", BindingFlags.Instance | BindingFlags.NonPublic | BindingFlags.InvokeMethod, System.Type.DefaultBinder, new Type[] { typeof(Field), typeof(Entity), typeof(StringBuilder) }, pmodifiers);
//Determine if our field type is a simple field, an array field, or a map field. Then, create an array
//of type parameters corresponding to the key and value types of the field.
//Note that GetFieldDatAsString takes two generic parameters, a key type and field(value) type.
//The 'key' type is only used for dictionary/map types, so pass an int type as a placeholder when
//processing simple and array fields.
Type[] methodGenericParameters = null;
if (currentField.ContainerType == ContainerType.Simple)
methodGenericParameters = new Type[] { typeof(int), currentField.ValueType }; //dummy int types for non dictionary type
else if (currentField.ContainerType == ContainerType.Array)
methodGenericParameters = new Type[] { typeof(int), currentField.ValueType }; //dummy int types for non dictionary type
else
methodGenericParameters = new Type[] { currentField.KeyType, currentField.ValueType };
//Instantiate a generic version of "GetFieldDataAsString" with the type parameters we just got from our field.
MethodInfo genericGetFieldDataAsStringmethodInstantiated = getFieldDataAsStringMethod.MakeGenericMethod(methodGenericParameters);
//Call that method to get the data out of that field.
genericGetFieldDataAsStringmethodInstantiated.Invoke(this, new object[] { currentField, storageEntity, strBuilder });
}
strBuilder.AppendLine("---------------------------------------------------------");
}
/// <summary>
/// Recursively gets all data from a field and appends it in string format to a StringBuilder.
/// </summary>
/// <typeparam name="KeyType">The key type of the field -- used only for maps</typeparam>
/// <typeparam name="FieldType">The data type of the field for simple types and arrays</typeparam>
/// <param name="field">The field to query</param>
/// <param name="entity">The entity to query</param>
/// <param name="strBuilder">The StringBuilder to append entity data to</param>
private void GetFieldDataAsString<KeyType, FieldType>(Field field, Entity entity, StringBuilder strBuilder)
{
string fieldName = field.FieldName;
System.Type fieldType = field.ValueType;
ForgeTypeId fieldUnit = field.GetSpecTypeId();
ContainerType fieldContainerType = field.ContainerType;
Type[] methodGenericParameters = null;
object[] invokeParams = null;
Type[] methodOverloadSelectionParams = null;
if (field.ContainerType == ContainerType.Simple)
methodGenericParameters = new Type[] { field.ValueType };
else if (field.ContainerType == ContainerType.Array)
methodGenericParameters = new Type[] { typeof(IList<int>).GetGenericTypeDefinition().MakeGenericType(new Type[] { field.ValueType }) };
else //map
methodGenericParameters = new Type[] { typeof(IDictionary<int, int>).GetGenericTypeDefinition().MakeGenericType(new Type[] { field.KeyType, field.ValueType }) };
if (fieldUnit.Empty())
{
methodOverloadSelectionParams = new Type[] { typeof(Field) };
invokeParams = new object[] { field };
}
else
{
methodOverloadSelectionParams = new Type[] { typeof(Field), typeof(ForgeTypeId) };
invokeParams = new object[] { field, UnitTypeId.Meters };
}
MethodInfo instantiatedGenericGetMethod = entity.GetType().GetMethod("Get", methodOverloadSelectionParams).MakeGenericMethod(methodGenericParameters);
if (field.ContainerType == ContainerType.Simple)
{
FieldType retval = (FieldType) instantiatedGenericGetMethod.Invoke(entity, invokeParams);
if (fieldType == typeof(Entity))
{
Schema subSchema = Schema.Lookup(field.SubSchemaGUID);
strBuilder.AppendLine("Field: " + field.FieldName + ", Type: " + field.ValueType.ToString() + ", Value: " + " {SubEntity} " + ", Unit: " + field.GetSpecTypeId().TypeId + ", ContainerType: " + field.ContainerType.ToString());
DumpAllSchemaEntityData<FieldType>(retval, subSchema, strBuilder);
}
else
{
string sRetval = retval.ToString();
strBuilder.AppendLine("Field: " + field.FieldName + ", Type: " + field.ValueType.ToString() + ", Value: " + retval + ", Unit: " + field.GetSpecTypeId().TypeId + ", ContainerType: " + field.ContainerType.ToString());
}
}
else if (field.ContainerType == ContainerType.Array)
{
IList<FieldType> listRetval = (IList<FieldType>)instantiatedGenericGetMethod.Invoke(entity, invokeParams);
if (fieldType == (typeof(Entity)))
{
strBuilder.AppendLine("Field: " + field.FieldName + ", Type: " + field.ValueType.ToString() + ", Value: " + " {SubEntity} " + ", Unit: " + field.GetSpecTypeId().TypeId + ", ContainerType: " + field.ContainerType.ToString());
foreach (FieldType fa in listRetval)
{
strBuilder.Append(" Array Value: ");
DumpAllSchemaEntityData<FieldType>(fa, Schema.Lookup(field.SubSchemaGUID), strBuilder);
}
}
else
{
strBuilder.AppendLine("Field: " + field.FieldName + ", Type: " + field.ValueType.ToString() + ", Value: " + " {Array} " + ", Unit: " + field.GetSpecTypeId().TypeId + ", ContainerType: " + field.ContainerType.ToString());
foreach (FieldType fa in listRetval)
{
strBuilder.AppendLine(" Array value: " + fa.ToString());
}
}
}
else //Map
{
strBuilder.AppendLine("Field: " + field.FieldName + ", Type: " + field.ValueType.ToString() + ", Value: " + " {Map} " + ", Unit: " + field.GetSpecTypeId().TypeId + ", ContainerType: " + field.ContainerType.ToString());
IDictionary<KeyType, FieldType> mapRetval = (IDictionary<KeyType, FieldType>)instantiatedGenericGetMethod.Invoke(entity, invokeParams);
if (fieldType == (typeof(Entity)))
{
strBuilder.AppendLine("Field: " + field.FieldName + ", Type: " + field.ValueType.ToString() + ", Value: " + " {SubEntity} " + ", Unit: " + field.GetSpecTypeId().TypeId + ", ContainerType: " + field.ContainerType.ToString());
foreach (FieldType fa in mapRetval.Values)
{
strBuilder.Append(" Map Value: ");
DumpAllSchemaEntityData<FieldType>(fa, Schema.Lookup(field.SubSchemaGUID), strBuilder);
}
}
else
{
strBuilder.AppendLine("Field: " + field.FieldName + ", Type: " + field.ValueType.ToString() + ", Value: " + " {Map} " + ", Unit: " + field.GetSpecTypeId().TypeId + ", ContainerType: " + field.ContainerType.ToString());
foreach (FieldType fa in mapRetval.Values)
{
strBuilder.AppendLine(" Map value: " + fa.ToString());
}
}
}
}
/// <summary>
/// Creates an instance of the RevitAPI.DLL assembly so we can query type information
/// from it
/// </summary>
private void SetRevitAssembly()
{
m_Assembly = System.Reflection.Assembly.GetAssembly(typeof(XYZ));
}
#endregion
#region Properties
/// <summary>
/// Gets the Autodesk.Revit.DB.ExtensibleStorage schema that the wrapper owns.
/// </summary>
/// <returns>An Autodesk.Revit.DB.ExtensibleStorage.Schema</returns>
public Schema GetSchema() { return m_Schema; }
/// <summary>
/// Sets the Autodesk.Revit.DB.ExtensibleStorage schema that the wrapper owns.
/// </summary>
/// <param name="schema">An Autodesk.Revit.DB.ExtensibleStorage.Schema</param>
public void SetSchema(Schema schema) { m_Schema = schema; }
/// <summary>
/// Gets and set the SchemaDataWrapper of the SchemaWrapper. "Set" is for serialization use only.
/// </summary>
public SchemaDataWrapper Data
{
get { return m_SchemaDataWrapper; }
set { m_SchemaDataWrapper = value; }
}
/// <summary>
/// Get the path of the xml file this Schema was generated from
/// </summary>
public string GetXmlPath()
{
return m_xmlPath;
}
/// <summary>
/// Set the path of the xml file this Schema was generated from
/// </summary>
public void SetXmlPath(string path)
{
m_xmlPath = path;
}
#endregion
#region Data
private SchemaDataWrapper m_SchemaDataWrapper;
[NonSerialized]
private Schema m_Schema;
[NonSerialized]
private SchemaBuilder m_SchemaBuilder;
[NonSerialized]
private System.Reflection.Assembly m_Assembly;
[NonSerialized]
private string m_xmlPath;
#endregion
}
}
@@ -0,0 +1,92 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
<ProductVersion>9.0.30729</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{D5227927-E688-4996-BEEE-7DCA91A7365B}</ProjectGuid>
<OutputType>Library</OutputType>
<AppDesignerFolder>Properties</AppDesignerFolder>
<RootNamespace>SchemaWrapperTools</RootNamespace>
<AssemblyName>SchemaWrapperTools</AssemblyName>
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion>
<FileAlignment>512</FileAlignment>
<TargetFrameworkProfile />
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' ">
<DebugSymbols>true</DebugSymbols>
<DebugType>full</DebugType>
<Optimize>false</Optimize>
<OutputPath>bin\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' ">
<DebugType>pdbonly</DebugType>
<Optimize>true</Optimize>
<OutputPath>bin\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<ErrorReport>prompt</ErrorReport>
<WarningLevel>4</WarningLevel>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Debug|x64'">
<DebugSymbols>true</DebugSymbols>
<OutputPath>bin\x64\Debug\</OutputPath>
<DefineConstants>DEBUG;TRACE</DefineConstants>
<DebugType>full</DebugType>
<PlatformTarget>x64</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)' == 'Release|x64'">
<OutputPath>bin\x64\Release\</OutputPath>
<DefineConstants>TRACE</DefineConstants>
<Optimize>true</Optimize>
<TreatWarningsAsErrors>true</TreatWarningsAsErrors>
<DebugType>pdbonly</DebugType>
<PlatformTarget>x64</PlatformTarget>
<ErrorReport>prompt</ErrorReport>
<CodeAnalysisRuleSet>MinimumRecommendedRules.ruleset</CodeAnalysisRuleSet>
</PropertyGroup>
<PropertyGroup>
<RunPostBuildEvent>OnOutputUpdated</RunPostBuildEvent>
</PropertyGroup>
<ItemGroup>
<Reference Include="System" />
<Reference Include="System.Core">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Xml.Linq">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data.DataSetExtensions">
<RequiredTargetFramework>3.5</RequiredTargetFramework>
</Reference>
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
</ItemGroup>
<ItemGroup>
<Compile Include="FieldData.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
<Compile Include="SchemaDataWrapper.cs" />
<Compile Include="SchemaWrapper.cs" />
</ItemGroup>
<Import Project="$(SolutionDir)VSProps\SDKSamples.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
<Target Name="AfterBuild">
</Target>
-->
<PropertyGroup>
<ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>None</ResolveAssemblyWarnOrErrorOnTargetArchitectureMismatch>
</PropertyGroup>
<PropertyGroup>
<PostBuildEvent>set FILEFORSAMPLEREG="$(SolutionDir)..\..\..\..\Regression\API\SDKSamples\UpdateSampleDllForRegression.pl"
if exist %25FILEFORSAMPLEREG%25 perl %25FILEFORSAMPLEREG%25 $(ProjectExt) "$(ProjectPath)" "$(TargetPath)" "$(SolutionDir)"</PostBuildEvent>
</PropertyGroup>
</Project>