AssetBundleGraph.NodeData.NodeData C# (CSharp) Method

NodeData() public method

public NodeData ( string name, NodeKind kind, float x, float y ) : System
name string
kind NodeKind
x float
y float
return System
        public NodeData(string name, NodeKind kind, float x, float y)
        {
            m_id = Guid.NewGuid().ToString();
            m_name = name;
            m_x = x;
            m_y = y;
            m_kind = kind;

            m_inputPoints  = new List<ConnectionPointData>();
            m_outputPoints = new List<ConnectionPointData>();

            // adding defalut input point.
            // Loader does not take input
            if(kind != NodeKind.LOADER_GUI) {
                m_inputPoints.Add(new ConnectionPointData(AssetBundleGraphSettings.DEFAULT_INPUTPOINT_LABEL, this, true));
            }

            // adding default output point.
            // Filter and Exporter does not have output.
            if(kind != NodeKind.FILTER_GUI && kind != NodeKind.EXPORTER_GUI) {
                m_outputPoints.Add(new ConnectionPointData(AssetBundleGraphSettings.DEFAULT_OUTPUTPOINT_LABEL, this, false));
            }

            switch(m_kind) {
            case NodeKind.PREFABBUILDER_GUI:
            case NodeKind.MODIFIER_GUI:
                m_scriptClassName 	= String.Empty;
                m_scriptInstanceData = new SerializableMultiTargetString();
                break;

            case NodeKind.IMPORTSETTING_GUI:
                break;

            case NodeKind.FILTER_GUI:
                m_filter = new List<FilterEntry>();
                break;

            case NodeKind.LOADER_GUI:
                m_loaderLoadPath = new SerializableMultiTargetString();
                break;

            case NodeKind.GROUPING_GUI:
                m_groupingKeyword = new SerializableMultiTargetString(AssetBundleGraphSettings.GROUPING_KEYWORD_DEFAULT);
                break;

            case NodeKind.BUNDLECONFIG_GUI:
                m_bundleConfigBundleNameTemplate = new SerializableMultiTargetString(AssetBundleGraphSettings.BUNDLECONFIG_BUNDLENAME_TEMPLATE_DEFAULT);
                m_variants = new List<Variant>();
                break;

            case NodeKind.BUNDLEBUILDER_GUI:
                m_bundleBuilderEnabledBundleOptions = new SerializableMultiTargetInt();
                break;

            case NodeKind.EXPORTER_GUI:
                m_exporterExportPath = new SerializableMultiTargetString();
                break;

            default:
                throw new AssetBundleGraphException("[FATAL]Unhandled nodekind. unimplmented:"+ m_kind);
            }
        }

Same methods

NodeData::NodeData ( object>.Dictionary jsonData ) : System