All Downloads are FREE. Search and download functionalities are using the official Maven repository.

services.aaa.UserOptionsService Maven / Gradle / Ivy

There is a newer version: 4.6.0
Show newest version
package services.aaa;

import static org.ovirt.api.metamodel.language.ApiLanguage.mandatory;

import org.ovirt.api.metamodel.annotations.In;
import org.ovirt.api.metamodel.annotations.InputDetail;
import org.ovirt.api.metamodel.annotations.Out;
import org.ovirt.api.metamodel.annotations.Service;

import annotations.Area;
import types.UserOption;

@Service
@Area("Infrastructure")
public interface UserOptionsService {
    /**
     * Adds a new user profile property of type JSON.
     *
     * Example request(for user with identifier `123`):
     *
     * [source]
     * ----
     * POST /ovirt-engine/api/users/123/options
     * ----
     *
     * Payload:
     *
     * [source,xml]
     * ----
     *   
     *     SomeName
     *     ["any", "JSON"]
     *   
     * ----
     * @author Radoslaw Szwajkowski 
     * @date 11 Jan 2021
     * @status added
     * @since 4.4.5
     */
    interface Add {
        @InputDetail
        default void inputDetail() {
            mandatory(option().content());
            mandatory(option().name());
        }

        @In @Out UserOption option();
    }

    /**
     * Returns a list of user profile properties of type JSON.
     *
     * Example request(for user with identifier `123`):
     *
     * [source]
     * ----
     * GET /ovirt-engine/api/users/123/options
     * ----
     *
     * The result will be the following XML document:
     *
     * [source,xml]
     * ----
     * 
     *   
     *     SomeName
     *     ["any", "JSON"]
     *     
     *   
     * 
     * ----
     * @author Radoslaw Szwajkowski 
     * @date 11 Jan 2021
     * @status added
     * @since 4.4.5
     */
    interface List {
        @Out UserOption[] options();
    }

    /**
     * @author Radoslaw Szwajkowski 
     * @date 11 Jan 2021
     * @status added
     * @since 4.4.5
     */
    @Service UserOptionService option(String id);
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy