private static bool HasAttribute <T>(this ProjectState state) { return(state.GetAttributes <T>().Length != 0); }
public static ControlTemplate GetAssociatedContent(this ProjectState state) { var atts = state.GetAttributes <AssociatedProjectStateVectorIconAttribute>(); return((atts.Length != 0) ? atts[0].ControlTemplate : null); }