added samples
[windows-sources.git] / sdk / samples / CrossTechnologySamples / RecipeViewer / recipeviewer / intefaceclasses / interfaceclasses.cs
blob2601a1278f458931f5a6050a54ae2999df003b77
1 // THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF
2 // ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO
3 // THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
4 // PARTICULAR PURPOSE.
5 //
6 // Copyright (c) Microsoft Corporation. All rights reserved.
7 using System;
8 using System.Collections;
9 using System.Collections.Generic;
10 using System.Xml;
11 using System.IO;
13 namespace Microsoft.Samples.RecipeCatalog
15 public enum RecipeAttachmentType
17 Unknown,
18 Photo,
19 Video
22 public interface IRecipeAttachment
25 RecipeAttachmentType Type
27 get;
30 String Name
32 get;
35 String Key
37 get;
40 Stream AttachmentStream
42 get;
46 public interface IRecipeAttachmentCollection : IEnumerable<IRecipeAttachment>
48 int Length
50 get;
53 IRecipeAttachment this[String key]
55 get;
59 public interface IRecipe
61 String Title
63 get;
66 int Rating
68 get;
71 String[] Keywords
73 get;
76 XmlDocument RecipeXml
78 get;
81 string Key
83 get;
86 IRecipeAttachmentCollection Attachments
88 get;
92 public interface IRecipeCollection : IEnumerator<IRecipe>, IEnumerable
94 int Length
96 get;
99 IRecipe this[String key]
101 get;
105 string AddRecipe(XmlReader recipeDoc);
106 IRecipeCollection Find(string[] keyword);