Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Revit 2022 #32

Merged
merged 3 commits into from
Jul 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
14 changes: 14 additions & 0 deletions Speckle.Host.Apis.sln
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Speckle.Revit2024.Fakes", "
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Speckle.Revit2024.Fakes.Generator", "Speckle.Revit2024.Fakes.Generator\Speckle.Revit2024.Fakes.Generator.csproj", "{F97FB46C-223C-4818-8A5A-330E897F4FC0}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Speckle.Revit2022.Fakes", "Speckle.Revit2022.Fakes\Speckle.Revit2022.Fakes.csproj", "{662B3B4B-5B46-4507-9A39-3320E82AD459}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Speckle.Revit2022.Fakes.Generator", "Speckle.Revit2022.Fakes.Generator\Speckle.Revit2022.Fakes.Generator.csproj", "{D2BD6A79-F43C-4D2C-A6AF-BEA5E91A380F}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -71,6 +75,14 @@ Global
{F97FB46C-223C-4818-8A5A-330E897F4FC0}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F97FB46C-223C-4818-8A5A-330E897F4FC0}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F97FB46C-223C-4818-8A5A-330E897F4FC0}.Release|Any CPU.Build.0 = Release|Any CPU
{662B3B4B-5B46-4507-9A39-3320E82AD459}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{662B3B4B-5B46-4507-9A39-3320E82AD459}.Debug|Any CPU.Build.0 = Debug|Any CPU
{662B3B4B-5B46-4507-9A39-3320E82AD459}.Release|Any CPU.ActiveCfg = Release|Any CPU
{662B3B4B-5B46-4507-9A39-3320E82AD459}.Release|Any CPU.Build.0 = Release|Any CPU
{D2BD6A79-F43C-4D2C-A6AF-BEA5E91A380F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D2BD6A79-F43C-4D2C-A6AF-BEA5E91A380F}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D2BD6A79-F43C-4D2C-A6AF-BEA5E91A380F}.Release|Any CPU.ActiveCfg = Release|Any CPU
{D2BD6A79-F43C-4D2C-A6AF-BEA5E91A380F}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(NestedProjects) = preSolution
{00F3BEC6-614D-4AEE-923A-0E2DF40FDE6B} = {42C36267-88A8-4F94-9E62-5D43A02D033C}
Expand All @@ -81,5 +93,7 @@ Global
{1F2F89EE-2032-4350-BFC9-6B74D477DE95} = {F2F213A8-6D57-492F-BA11-C9F26057B1DA}
{A73658B1-0C37-4EAD-AAF8-8FECD2EEFC9A} = {BD68BFA8-3EC7-4689-987E-6422A37CF3B0}
{F97FB46C-223C-4818-8A5A-330E897F4FC0} = {3B0D8F6E-C701-446E-BAE3-B6FDF1812901}
{662B3B4B-5B46-4507-9A39-3320E82AD459} = {BD68BFA8-3EC7-4689-987E-6422A37CF3B0}
{D2BD6A79-F43C-4D2C-A6AF-BEA5E91A380F} = {3B0D8F6E-C701-446E-BAE3-B6FDF1812901}
EndGlobalSection
EndGlobal
47 changes: 47 additions & 0 deletions Speckle.Revit2022.Fakes.Generator/Program.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
using System.Reflection;
using Speckle.Shared;

var asm = Assembly.GetEntryAssembly();
Assembly GetAssembly(string name)
{
var path = Path.Combine(Path.GetDirectoryName(asm.Location), name);
return Assembly.ReflectionOnlyLoadFrom(path);
}

Generator generator =
new(
"Speckle.Revit2022.Fakes",
[GetAssembly("RevitAPI.dll"), GetAssembly("RevitAPIUI.dll")],
[
"Autodesk.Revit.DB",
"Autodesk.Revit.DB.Architecture",
"Autodesk.Revit.ApplicationServices",
"Autodesk.Revit.Creation",
"Autodesk.Revit.UI",
"Autodesk.Revit.DB.ExtensibleStorage",
"Autodesk.Revit.DB.ExternalService",
"Autodesk.Revit.DB.Structure",
"Autodesk.Revit.DB.Electrical",
"Autodesk.Revit.DB.Plumbing",
"Autodesk.Revit.DB.Fabrication",
"Autodesk.Revit.DB.Mechanical",
"Autodesk.Revit.DB.Analysis",
"Autodesk.Revit.DB.PointClouds",
"Autodesk.Revit.Exceptions"
],
[
new("WallSweepInfo", []),
new("ToggleButtonData", []),
new("RadioButtonGroup", []),
new("PanelScheduleTemplate", [new("IsValidType")]),
new("FabricReinSpanSymbol", [new("Create")]),
new("PathReinSpanSymbol", [new("Create")]),
new("RebarSystemSpanSymbol", [new("Create")]),
new("ProjectInfo", [new("Name")]),
new("Dimension", [new("Name")]),
new("ReferencePlane", [new("Name")]),
new("ImageView", [new("Create")])
],
GeneratorOptions.ExplicitProperties
);
generator.Generate();
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net48</TargetFramework>
<PlatformTarget>x64</PlatformTarget>
</PropertyGroup>
<Import Project="..\Speckle.Shared\Speckle.Shared.projitems" Label="Shared" />
<ItemGroup>
<PackageReference Include="Speckle.Revit.API" VersionOverride="2022.0.2.1" />
</ItemGroup>
</Project>
46 changes: 46 additions & 0 deletions Speckle.Revit2022.Fakes.Generator/packages.lock.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,46 @@
{
"version": 2,
"dependencies": {
".NETFramework,Version=v4.8": {
"Microsoft.SourceLink.GitHub": {
"type": "Direct",
"requested": "[8.0.0, )",
"resolved": "8.0.0",
"contentHash": "G5q7OqtwIyGTkeIOAc3u2ZuV/kicQaec5EaRnc0pIeSnh9LUjj+PYQrJYBURvDt7twGl2PKA7nSN0kz1Zw5bnQ==",
"dependencies": {
"Microsoft.Build.Tasks.Git": "8.0.0",
"Microsoft.SourceLink.Common": "8.0.0"
}
},
"MinVer": {
"type": "Direct",
"requested": "[5.0.0, )",
"resolved": "5.0.0",
"contentHash": "ybkgpQMtt0Fo91l5rYtE3TZtD+Nmy5Ko091xvfXXOosQdMi30XO2EZ2+ShZt89gdu7RMmJqZaJ+e1q6d+6+KNw=="
},
"PolySharp": {
"type": "Direct",
"requested": "[1.14.1, )",
"resolved": "1.14.1",
"contentHash": "mOOmFYwad3MIOL14VCjj02LljyF1GNw1wP0YVlxtcPvqdxjGGMNdNJJxHptlry3MOd8b40Flm8RPOM8JOlN2sQ=="
},
"Speckle.Revit.API": {
"type": "Direct",
"requested": "[2022.0.2.1, )",
"resolved": "2022.0.2.1",
"contentHash": "IrLN4WyI2ix+g3zCpo7sX8zNB3FrtrdQ3E2RpceGVPNG00v8OfD+Kei7o1bn1u/ML46iBYRAr/JcsLbwfUQsBw=="
},
"Microsoft.Build.Tasks.Git": {
"type": "Transitive",
"resolved": "8.0.0",
"contentHash": "bZKfSIKJRXLTuSzLudMFte/8CempWjVamNUR5eHJizsy+iuOuO/k2gnh7W0dHJmYY0tBf+gUErfluCv5mySAOQ=="
},
"Microsoft.SourceLink.Common": {
"type": "Transitive",
"resolved": "8.0.0",
"contentHash": "dk9JPxTCIevS75HyEQ0E4OVAFhB2N+V9ShCXf8Q6FkUQZDkgLI12y679Nym1YqsiSysuQskT7Z+6nUf3yab6Vw=="
}
},
".NETFramework,Version=v4.8/win7-x64": {}
}
}
102 changes: 102 additions & 0 deletions Speckle.Revit2022.Fakes/Enumerables.Plumbing.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,102 @@
using System.Collections;
using System.Collections.Generic;

namespace Autodesk.Revit.DB.Plumbing
{
public partial class FluidTemperatureSetIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class FluidType
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}
}

namespace Autodesk.Revit.DB.Electrical
{
public partial class CableTraySizeIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class CableTraySizes
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class ConduitSizeIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class ConduitSizes
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class ConduitSizeSettingIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class ConduitSizeSettings
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}
}

namespace Autodesk.Revit.DB.Mechanical
{
public partial class DuctSizeIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class DuctSizes
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class DuctSizeSettingIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class DuctSizeSettings
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}
}

namespace Autodesk.Revit.DB.Structure
{
public partial class RebarContainer
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class RebarContainerIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}
}

namespace Autodesk.Revit.DB.PointClouds
{
public partial class PointCollection
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class PointIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class CloudPoint
{
public static implicit operator XYZ(CloudPoint cp) => new(cp.X, cp.Y, cp.Z);
}
}
134 changes: 134 additions & 0 deletions Speckle.Revit2022.Fakes/Enumerables.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,134 @@
using System.Collections;
using System.Collections.Generic;

namespace Autodesk.Revit.DB;

public partial class Definitions
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class CurveLoop
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class ExportFontTable
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class ExportPatternTable
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class ExportLineweightTableIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class ExportPatternTableIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class ExportFontTableIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class CurveLoopIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class ExportLayerTableIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class ExportLinetypeTableIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class GeometryElement
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class ExportLinetypeTable
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class ExportLineweightTable
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class ExportLayerTable
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class SolidCurveIntersection
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class KeyBasedTreeEntries
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class FilteredElementCollector
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class FilteredWorksetCollector
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class DefinitionGroups
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class ComponentRepeater
{
IEnumerator IEnumerable.GetEnumerator() => throw new System.NotImplementedException();
}

public partial class ComponentRepeaterIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class KeyBasedTreeEntriesIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class FilteredElementIdIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class FilteredElementIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class FilteredWorksetIdIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}

public partial class FilteredWorksetIterator
{
object IEnumerator.Current => throw new System.NotImplementedException();
}
9 changes: 9 additions & 0 deletions Speckle.Revit2022.Fakes/Speckle.Revit2022.Fakes.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<IsPackable>true</IsPackable>
</PropertyGroup>
<ItemGroup>
<PackageReference Include="System.Drawing.Common" />
</ItemGroup>
</Project>
Loading