Class DefaultProfileSet

    • Constructor Detail

      • DefaultProfileSet

        public DefaultProfileSet​(String baseProfile)
        Public constructor.
        Parameters:
        baseProfile - The base profile for the profile set.
      • DefaultProfileSet

        public DefaultProfileSet​(String baseProfile,
                                 String[] subProfiles)
    • Method Detail

      • getBaseProfile

        public String getBaseProfile()
        Get the base profile for this profile set.
        Specified by:
        getBaseProfile in interface ProfileSet
        Returns:
        Base profile name.
      • isMember

        public boolean isMember​(String profile)
        Description copied from interface: ProfileSet
        Is the specified profile a member of this profile set.

        A profile is said to be a member of a profile set if it is the base profile of the profile set, or one of its sub profiles.

        Specified by:
        isMember in interface ProfileSet
        Parameters:
        profile - The profile to check against.
        Returns:
        True if the associated device a member of the specified profile, otherwise false.
      • addProfile

        public void addProfile​(String profile)
        Add profile to the ProfileSet.
        Parameters:
        profile - The profile to add.
      • addProfile

        public void addProfile​(Profile profile)
        Add profile to the ProfileSet.
        Specified by:
        addProfile in interface ProfileSet
        Parameters:
        profile - The profile to add.
      • getProfile

        public Profile getProfile​(String profile)
        Get a profile from the ProfileSet.
        Specified by:
        getProfile in interface ProfileSet
        Parameters:
        profile - The name of the profile.
        Returns:
        The requested Profile, or null if the profile is not a member of the ProfileSet.
      • addProfileSet

        protected void addProfileSet​(DefaultProfileSet profileSet)
        Add the profiles of the supplied DefaultProfileSet to this ProfileSet.
        Parameters:
        profileSet - The DefaultProfileSet whose profiles are to be added.
      • addProfiles

        public void addProfiles​(String[] subProfiles)
        Add a list of subProfiles to the ProfileSet.
        Parameters:
        subProfiles - The array of sub Profiles to add.