Foreign/SonyLE/LevelEditor/DomNodeAdapters/PrefabInstance.cs
/// <summary>
/// Gets AttributeOverride by name
/// if not found then it will create new instacne</summary>        
Gets AttributeOverride by name
if not found then it will create new instacne
Gets AttributeOverride by name if not found then it will create new instacne
public AttributeOverride GetOrCreateByName(string name)
        {
            if (string.IsNullOrWhiteSpace(name))
                throw new InvalidOperationException("name cannot be null or empty");
            foreach (var attrib in m_overrides)
            {
                if (attrib.Name == name)
                    return attrib;
            }
            AttributeOverride attrOverride = AttributeOverride.Create(name, "");
            m_overrides.Add(attrOverride);
            return attrOverride;
        }
public AttributeOverride GetOrCreateByName ( string name ) { if ( string . IsNullOrWhiteSpace ( name ) ) throw new InvalidOperationException ( " " ) ; foreach ( var attrib in m_overrides ) { if ( attrib . Name == name ) return attrib ; } AttributeOverride attrOverride = AttributeOverride . Create ( name , " " ) ; m_overrides . Add ( attrOverride ) ; return attrOverride ; }
Gets AttributeOverride by name
if not found then it will create new instacne
Gets AttributeOverride by name if not found then it will create new instacne
//note:linear search is OK there are not many items. // find AttributeOverride by name. // if not found  create new instance and add it to the list.
name
string