//------------------------------------------------------------------------- public override void load(EbPropSet prop_set) { Name = prop_set.getPropString("T_Name").get(); var prop_state = prop_set.getPropInt("I_State"); State = prop_state == null ? DataState.Default : (DataState)prop_state.get(); string strPoints = prop_set.getPropString("T_Points").get(); if (!string.IsNullOrEmpty(strPoints)) { ListPoints = new List <EbVector3>(); string[] arrayPoints = strPoints.Split(';'); bool is_x = true; float x = 0; foreach (var it in arrayPoints) { if (is_x) { x = float.Parse(it); is_x = false; } else { ListPoints.Add(new EbVector3(x, float.Parse(it), 0)); is_x = true; } } } var prop_type = prop_set.getPropInt("I_Type"); Type = prop_type == null ? RouteType.Default : (RouteType)prop_type.get(); var prop_routecategory = prop_set.getPropInt("I_RouteCategory"); routeCategory = prop_routecategory == null ? RouteCategory.Default : (RouteCategory)prop_routecategory.get(); }
protected void Add(string method, string path, RouteCategory category, Type actionType, IEndpointInvocation invocation, string?description, string?tag) { Registrations.Add(new EndpointRegistration(method, path, category, invocation, description, tag, actionType)); }
public EndpointRegistration(string method, string path, RouteCategory category, IEndpointInvocation invocation, string?description, string?tag, Type actionType) { Method = method; Path = path; Category = category; Invocation = invocation; Description = description; Tag = tag; ActionType = actionType; }
protected void Add <TAction>(string method, string path, RouteCategory category, IEndpointInvocation invocation, string?description, string?tag) where TAction : IAsyncApiAction { Registrations.Add(new EndpointRegistration(method, path, category, invocation, description, tag, typeof(TAction))); }