Class Scorm2004Resources

java.lang.Object
dev.jcputney.elearning.parser.input.scorm2004.ims.cp.Scorm2004Resources
All Implemented Interfaces:
Serializable

public final class Scorm2004Resources extends Object implements Serializable
Represents the collection of resources within the content package. Each resource defines a learning object or asset.
See Also:
  • Constructor Details

    • Scorm2004Resources

      public Scorm2004Resources()
      Default constructor for the Scorm2004Resources class. This constructor creates an instance of the Scorm2004Resources class with no initial parameters.
  • Method Details

    • getBase

      public String getBase()
      Retrieves the base URL for all resources in the content package. This URL is used to resolve relative paths for resources.
      Returns:
      the base URL as a String
    • setBase

      public void setBase(String base)
      Sets the base URL for all resources in the content package. The base URL is used to resolve relative paths for the resources.
      Parameters:
      base - the base URL as a string to be used for resolving resource paths
    • getResourceList

      public List<Scorm2004Resource> getResourceList()
      Retrieves the list of SCORM 2004 resources contained in the content package.
      Returns:
      a list of Scorm2004Resource objects representing the resources in the content package
    • setResourceList

      public void setResourceList(List<Scorm2004Resource> resourceList)
      Sets the list of SCORM 2004 resources contained in the content package.
      Parameters:
      resourceList - the list of Scorm2004Resource objects to be set as the resources in the content package
    • getResourceById

      public Optional<Scorm2004Resource> getResourceById(String id)
      Retrieves a resource by its identifier.
      Parameters:
      id - The identifier of the resource to retrieve.
      Returns:
      An Optional containing the resource if found, or an empty Optional if not found.
    • equals

      public boolean equals(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object