SobekCM.Core.Client.SobekEngineClient_ItemEndpoints.Get_Multiple_Volumes C# (CSharp) Method

Get_Multiple_Volumes() public method

Gets the list of items (VIDs) under a single title (BibID)
public Get_Multiple_Volumes ( string BibID, Custom_Tracer Tracer ) : List
BibID string Bibliographic identifier (BibID) for the digital resources
Tracer SobekCM.Tools.Custom_Tracer Trace object keeps a list of each method executed and important milestones in rendering
return List
        public List<Item_Hierarchy_Details> Get_Multiple_Volumes(string BibID, Custom_Tracer Tracer)
        {
            // Add a beginning trace
            Tracer.Add_Trace("SobekEngineClient_ItemEndpoints.Get_Multiple_Volumes", "Get list of items under a single BibID");

            // Look in the cache
            if (Config.UseCache)
            {
                List<Item_Hierarchy_Details> fromCache = CachedDataManager.Items.Retrieve_Item_List(BibID, Tracer);
                if (fromCache != null)
                {
                    Tracer.Add_Trace("SobekEngineClient_ItemEndpoints.Get_Multiple_Volumes", "Found list of items on the local cache");
                    return fromCache;
                }
            }
            // Get the endpoint
            MicroservicesClient_Endpoint endpoint = GetEndpointConfig("Items.GetMultipleVolumes", Tracer);

            // Format the URL
            string url = String.Format(endpoint.URL, BibID);

            // Call out to the endpoint and deserialize the object
            List<Item_Hierarchy_Details> returnValue = Deserialize<List<Item_Hierarchy_Details>>(url, endpoint.Protocol, Tracer);

            // Add to the local cache
            if ((Config.UseCache) && (returnValue != null))
            {
                Tracer.Add_Trace("SobekEngineClient_ItemEndpoints.Get_Multiple_Volumes", "Store list of items on the local cache");
                CachedDataManager.Items.Store_Item_List(BibID, returnValue, Tracer);
            }

            // Return the object
            return returnValue;
        }