/// <summary> /// 전달받은 서비스 시스템을 API사용 불가능 하도록 제거합니다. /// 단 이미 참조중일경우 중지는 따로 명령을 내려야함 /// </summary> /// <param name="serviceSystem"></param> /// <returns></returns> public bool Unregister(ServiceSystem serviceSystem) { bool b = m_ServiceList.Remove(serviceSystem); //만약 서비스 시스템 리스트가 비어있다면 비어있는 시스템 등록 if (m_ServiceList.Count == 0) { m_ServiceList.Add(EmptyServiceSystem); } return(b); }
/// <summary> /// 전달 받은 시스템을 API에서 사용 가능하도록 등록합니다. /// 등록시스템에 등록된 이름이랑 중복되는 객체가 존재 한다면 /// 등록에 실패하여 false를 반환합니다. /// </summary> /// <param name="serviceSystem"></param> public bool Register(ServiceSystem serviceSystem) { //처음 등록되는 경우 if (m_ServiceList.Contains(EmptyServiceSystem) == true) { m_ServiceList.Clear(); } if (GetService(serviceSystem.Name) == null) { m_ServiceList.Add(serviceSystem); return(true); } else { return(false); } }