import
{
    IdLocationNameIdentityDTO,
    ResponseContainerDTO
} from "./Windream.WebService";

import { DocumentResponseDTO } from "./Windream.WebService.Documents";
import { AttributeFlagsValuesDTO } from "./Windream.WebService.Attributes";


export interface IFavoritesControllerDTO
{
    GetMyWindreamFolders(): MyWindreamFolderResponseContainerDTO[];
    GetFavorites(parameter: GetFavoritesContentDTO): FavoritesItemResponseContainerDTO[];
    AddFavorites(parameter: SetFavoritesContentDTO): FavoritesItemResponseContainerDTO[];
    RemoveFavorites(parameter: SetFavoritesContentDTO): FavoritesItemResponseContainerDTO[];
}

export enum MyWindreamSections
{
    Undefined = 0,
    Global = 1,
    Private = 2
}

export enum MyWindreamObjectTypes
{
    Undefined = 0,
    Folder = 1,
    FavoritesFolder = 4,
    RecycleBin = 9,
    PrivateFolder = 11,
    PrivateUser = 12
}

export interface FavoritesFolderIdentityDTO
{
    MyWindreamSection: MyWindreamSections;
    Location: String;
}

export interface FavoritesItemResponseContainerDTO extends ResponseContainerDTO
{
    Item: DocumentResponseDTO;
    FavoritesFolder: FavoritesFolderIdentityDTO;
}

export interface GetFavoritesContentDTO extends AttributeFlagsValuesDTO
{
    FavoritesFolder: FavoritesFolderIdentityDTO;
}

export interface MyWindreamFolderResponseContainerDTO extends ResponseContainerDTO
{
    Item: NodeLeafResponseDTO;
}

export interface NodeLeafResponseDTO
{
    MyWindreamType: MyWindreamObjectTypes;
    NodeLeafId: number;
    ParentId: number;
    Name: String;
    DisplayName: String;
}

export interface SetFavoritesContentDTO
{
    Items: IdLocationNameIdentityDTO;
    FavoritesFolder: FavoritesFolderIdentityDTO;
}