public ToTreeNode ( IEntity entity ) : IBooParseTreeNode | ||
entity | IEntity | |
return | IBooParseTreeNode |
public IBooParseTreeNode ToTreeNode(IEntity entity)
{
if (entity is IType)
return ToTreeNode((IType)entity);
if (entity is IProperty)
return ToTreeNode((IProperty)entity);
if (entity is IMethod)
return ToTreeNode((IMethod)entity);
if (entity is INamespace)
return ToTreeNode((INamespace)entity);
// fallback for unhandled types
return new ClassTreeNode(new EntitySourceOrigin(entity), entity.FullName);
}
EntityToTreeNodeConverter::ToTreeNode ( IMethod method ) : IBooParseTreeNode | |
EntityToTreeNodeConverter::ToTreeNode ( INamespace @namespace ) : IBooParseTreeNode | |
EntityToTreeNodeConverter::ToTreeNode ( IProperty property ) : IBooParseTreeNode | |
EntityToTreeNodeConverter::ToTreeNode ( IType type ) : IBooParseTreeNode |
public IBooParseTreeNode ToTreeNode() { var converter = new EntityToTreeNodeConverter(); return converter.ToTreeNode(entity); }