TSplineEdge
using Autodesk.DesignScript.Interfaces;
using Autodesk.DesignScript.Runtime;
using System.Collections.Generic;
using System.Linq;
namespace Autodesk.DesignScript.Geometry.TSpline
{
public class TSplineEdge : Edge
{
internal ITSplineEdgeEntity TSplineEdgeEntity => HostImpl as ITSplineEdgeEntity;
[IsVisibleInDynamoLibrary(false)]
public new TSplineFace[] AdjacentFaces {
get {
return TSplineFace.Wrap(TSplineEdgeEntity.get_AdjacentFaces(), true);
}
}
[IsVisibleInDynamoLibrary(false)]
public new TSplineVertex StartVertex {
get {
return TSplineVertex.Wrap(TSplineEdgeEntity.get_StartVertex(), true);
}
}
[IsVisibleInDynamoLibrary(false)]
public new TSplineVertex EndVertex {
get {
return TSplineVertex.Wrap(TSplineEdgeEntity.get_EndVertex(), true);
}
}
public TSplineUVNFrame UVNFrame => TSplineUVNFrame.Wrap(TSplineEdgeEntity.get_UVNFrame(), true);
public int Index => TSplineEdgeEntity.get_Index();
public bool IsBorder => TSplineEdgeEntity.get_IsBorder();
public bool IsManifold => TSplineEdgeEntity.get_IsManifold();
internal TSplineEdge(ITSplineEdgeEntity host, bool persist)
: base(host, persist)
{
}
public override string ToString()
{
object[] obj = new object[7] {
"TSplineEdge(Index = ",
Index,
", IsBorder = ",
null,
null,
null,
null
};
bool flag = IsBorder;
obj[3] = flag.ToString();
obj[4] = ", IsManifold = ";
flag = IsManifold;
obj[5] = flag.ToString();
obj[6] = ")";
return string.Concat(obj);
}
internal static TSplineEdge Wrap(ITSplineEdgeEntity host, bool persist = true)
{
if (host == null)
return null;
return new TSplineEdge(host, persist);
}
internal static TSplineEdge[] Wrap(ITSplineEdgeEntity[] hosts, bool persist = true)
{
return (from x in hosts
select Wrap(x, persist)).ToArray();
}
internal static TSplineEdge[][] Wrap(ITSplineEdgeEntity[][] hosts, bool persist = true)
{
return (from x in hosts
select Wrap(x, persist)).ToArray();
}
internal static ITSplineEdgeEntity[][] Unwrap(TSplineEdge[][] o)
{
return (from x in o
select Unwrap(x)).ToArray();
}
internal static ITSplineEdgeEntity[] Unwrap(TSplineEdge[] o)
{
return (from x in o
select Unwrap(x)).ToArray();
}
internal static ITSplineEdgeEntity[] Unwrap(IEnumerable<TSplineEdge> o)
{
return (from x in o
select Unwrap(x)).ToArray();
}
internal static ITSplineEdgeEntity Unwrap(TSplineEdge o)
{
return o.TSplineEdgeEntity;
}
[MultiReturn(new string[] {
"uvnFrame",
"index",
"isBorder",
"isManifold"
})]
public Dictionary<string, object> Info()
{
Dictionary<string, object> dictionary = new Dictionary<string, object>();
foreach (KeyValuePair<string, object> item in TSplineEdgeEntity.Info()) {
string key = item.Key;
if (key == "uvnFrame")
dictionary[item.Key] = TSplineUVNFrame.Wrap(item.Value as ITSplineUVNFrameEntity, true);
else
dictionary[item.Key] = item.Value;
}
return dictionary;
}
}
}