public bool Has <T>(out T component) where T : Component { ComponentHelper.Assert <T>(); try { component = ComponentHelper.CallGet <T>(Handle); return(true); } catch (Exception) { component = default; return(false); } }
public T Get <T>() where T : Component { ComponentHelper.Assert <T>(); /*var registerAs = ComponentHelper.GetRegisterAs<T>(); * if (registerAs != null) { * return registerAs.CallGet<T>(Handle); * } * return Handle.Get<T>();*/ return(ComponentHelper.CallGet <T>(Handle)); }