doc
 All Classes Functions Variables Properties
/Users/rburkes/Projects/mobile/branches/release-1-2/devices/iphone/core/src/EMLib/EMContentItem.h
00001 /*
00002 Copyright 2001, 2012, Oracle and/or its affiliates. All rights reserved.
00003 Oracle and Java are registered trademarks of Oracle and/or its 
00004 affiliates. Other names may be trademarks of their respective owners.
00005 UNIX is a registered trademark of The Open Group.
00006 
00007 This software and related documentation are provided under a license 
00008 agreement containing restrictions on use and disclosure and are 
00009 protected by intellectual property laws. Except as expressly permitted 
00010 in your license agreement or allowed by law, you may not use, copy, 
00011 reproduce, translate, broadcast, modify, license, transmit, distribute, 
00012 exhibit, perform, publish, or display any part, in any form, or by any 
00013 means. Reverse engineering, disassembly, or decompilation of this 
00014 software, unless required by law for interoperability, is prohibited.
00015 The information contained herein is subject to change without notice 
00016 and is not warranted to be error-free. If you find any errors, please 
00017 report them to us in writing.
00018 U.S. GOVERNMENT END USERS: Oracle programs, including any operating 
00019 system, integrated software, any programs installed on the hardware, 
00020 and/or documentation, delivered to U.S. Government end users are 
00021 "commercial computer software" pursuant to the applicable Federal 
00022 Acquisition Regulation and agency-specific supplemental regulations. 
00023 As such, use, duplication, disclosure, modification, and adaptation 
00024 of the programs, including any operating system, integrated software, 
00025 any programs installed on the hardware, and/or documentation, shall be 
00026 subject to license terms and license restrictions applicable to the 
00027 programs. No other rights are granted to the U.S. Government.
00028 This software or hardware is developed for general use in a variety 
00029 of information management applications. It is not developed or 
00030 intended for use in any inherently dangerous applications, including 
00031 applications that may create a risk of personal injury. If you use 
00032 this software or hardware in dangerous applications, then you shall 
00033 be responsible to take all appropriate fail-safe, backup, redundancy, 
00034 and other measures to ensure its safe use. Oracle Corporation and its 
00035 affiliates disclaim any liability for any damages caused by use of this 
00036 software or hardware in dangerous applications.
00037 This software or hardware and documentation may provide access to or 
00038 information on content, products, and services from third parties. 
00039 Oracle Corporation and its affiliates are not responsible for and 
00040 expressly disclaim all warranties of any kind with respect to 
00041 third-party content, products, and services. Oracle Corporation and 
00042 its affiliates will not be responsible for any loss, costs, or damages 
00043 incurred due to your access to or use of third-party content, products, 
00044 or services.
00045 */
00046 
00047 
00048 #import <Foundation/Foundation.h>
00049 #import "UIColorAdditions.h"
00050 
00059 @interface EMContentItem : NSObject {
00060         NSString *_templateId, *_type, *_name;
00061         NSMutableArray *_props;
00062 }
00063 
00067 @property (nonatomic, retain) NSString *templateId;
00068 
00072 @property (nonatomic, retain) NSString *type;
00073 
00077 @property (nonatomic, retain) NSString *name;
00078 
00082 @property (nonatomic, retain) NSMutableArray *props;
00083 
00084 @end
00085 
00086 
00087 #pragma mark -
00088 
00089 
00090 @interface EMContentItemProperty : NSObject {
00091         NSString *_name, *_contentType;
00092         
00093         NSObject *_value;
00094 }
00095 
00099 @property (nonatomic, retain) NSString *name;
00100 
00101 /*
00102  *
00103  */
00104 @property (nonatomic, retain) NSString *contentType;
00105 
00106 /*
00107  *
00108  */
00109 @property (nonatomic, retain) NSObject *value;
00110 
00111 @end
00112 
00113 
00114 #pragma mark -
00115 
00116 @class EMSearchQuery;
00117 
00118 @interface EMNavStateRecordList : NSObject {
00119         EMSearchQuery *_searchQuery;
00120         
00121         NSMutableArray *_records;
00122         
00123         NSInteger _totalRecords;
00124 }
00125 
00129 @property (nonatomic, retain) EMSearchQuery *searchQuery;
00130 
00134 @property (nonatomic, retain) NSMutableArray *records;
00135 
00139 @property (nonatomic, assign) NSInteger totalRecords;
00140 
00141 @end
00142 
00143 
00144 #pragma mark -
00145 
00146 
00147 typedef enum {
00148         EMNavStateItemStyleNormal = 0,
00149         EMNavStateItemStyleIcon = 1,
00150         EMNavStateItemStyleIconGlossy = 2
00151 } EMNavStateItemStyle;
00152 
00153 typedef enum {
00154         EMNavStateItemHeaderStylePlain = 4,
00155         EMNavStateItemHeaderStyleRound = 5,
00156         EMNavStateItemHeaderStyleRoundImage = 6
00157 } EMNavStateItemHeaderStyle;
00158 
00159 
00160 @class EMSearchQuery, EMNavStateGroup;
00161 
00162 @interface EMNavStateItem : NSObject <NSCopying> {
00163         EMSearchQuery *_searchQuery;
00164         NSString *_targetURI;
00165         
00166         NSString *_text;
00167         UIColor *_textColor;
00168         NSString *_detailText;
00169 
00170         NSString *_iconURL;     
00171         BOOL _prerenderedIcon;
00172         BOOL _bannerIcon;
00173         NSUInteger _iconHeight;
00174         NSUInteger _iconWidth;  
00175         
00176         BOOL _augmentNavState;
00177         
00178         EMNavStateGroup *_parent;
00179 }
00180 
00184 @property (nonatomic, retain) EMSearchQuery *searchQuery;
00185 
00189 @property (nonatomic, retain) NSString *targetURI;
00190 
00194 @property (nonatomic, retain) NSString *text;
00195 
00196 /*
00197  *
00198  */
00199 @property (nonatomic, retain) UIColor *textColor;
00200 
00204 @property (nonatomic, retain) NSString *detailText;
00205 
00209 @property (nonatomic, retain) NSString *iconURL;
00210 
00216 @property (nonatomic, assign) BOOL bannerIcon;
00217 
00221 @property (nonatomic, assign) NSUInteger iconHeight;
00222 
00226 @property (nonatomic, assign) NSUInteger iconWidth;
00227 
00234 @property (nonatomic, assign) BOOL augmentNavState;
00235 
00239 @property (nonatomic, assign) EMNavStateGroup *parent;
00240 
00244 - (BOOL) hasTarget;
00245 
00246 @end
00247 
00248 
00249 #pragma mark -
00250 
00251 
00252 @interface EMNavStateItemList : NSObject {
00253         NSMutableArray *_items;
00254 
00255 }
00256 
00260 @property (nonatomic, retain) NSMutableArray *items;
00261 
00265 - (void) addItem:(EMNavStateItem *)item;
00266 
00267 @end
00268 
00269 
00270 #pragma mark -
00271 
00272 
00273 @class EMNavStateGroupList;
00274 
00275 @interface EMNavStateGroup : EMNavStateItemList {
00276         EMNavStateItem *_headerItem;
00277         
00278         EMNavStateGroupList *_parent;
00279 }
00280 
00284 @property (nonatomic, retain) EMNavStateItem *headerItem;
00285 
00289 @property (nonatomic, assign) EMNavStateGroupList *parent;
00290 
00295 - (void) addItem:(EMNavStateItem *)item;
00296 
00297 @end
00298 
00299 
00300 #pragma mark -
00301 
00302 
00303 typedef enum {
00304         EMNavStateGroupListStylePlain = 0,
00305         EMNavStateGroupListStyleRound = 1
00306 } EMNavStateGroupListStyle;
00307 
00308 
00309 @interface EMNavStateGroupList : NSObject {
00310         
00311         NSMutableArray *_groups;
00312         
00313         EMNavStateGroupListStyle _groupStyle;
00314         EMNavStateItemStyle _itemStyle;
00315         EMNavStateItemHeaderStyle _headerItemStyle;
00316         
00317         NSUInteger _defaultRowHeight;
00318         NSUInteger _defaultTextFontSize;
00319         NSUInteger _defaultDetailTextFontSize;
00320         UIColor *_defaultDetailTextColor;
00321         
00322 }
00323 
00328 - (void) addGroup:(EMNavStateGroup *)group;
00329 
00334 @property (nonatomic, retain) NSMutableArray *groups;
00335 
00339 @property (nonatomic) EMNavStateGroupListStyle groupStyle;
00340 
00344 @property (nonatomic) EMNavStateItemStyle itemStyle;
00348 @property (nonatomic) EMNavStateItemHeaderStyle headerItemStyle;
00349 
00350 
00354 @property (nonatomic) NSUInteger defaultRowHeight;
00355 
00359 @property (nonatomic) NSUInteger defaultTextFontSize;
00360 
00364 @property (nonatomic) NSUInteger defaultDetailTextFontSize;
00365 
00369 @property (nonatomic, retain) UIColor *defaultDetailTextColor;
00370 
00371 
00372 @end
00373