Symbian3/SDK/Source/GUID-5E8AA6B6-38EB-5347-BA30-F9FF4BF7C107.dita
changeset 7 51a74ef9ed63
child 8 ae94777fff8f
equal deleted inserted replaced
6:43e37759235e 7:51a74ef9ed63
       
     1 <?xml version="1.0" encoding="utf-8"?>
       
     2 <!-- Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies) All rights reserved. -->
       
     3 <!-- This component and the accompanying materials are made available under the terms of the License 
       
     4 "Eclipse Public License v1.0" which accompanies this distribution, 
       
     5 and is available at the URL "http://www.eclipse.org/legal/epl-v10.html". -->
       
     6 <!-- Initial Contributors:
       
     7     Nokia Corporation - initial contribution.
       
     8 Contributors: 
       
     9 -->
       
    10 <!DOCTYPE concept
       
    11   PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd">
       
    12 <concept id="GUID-5E8AA6B6-38EB-5347-BA30-F9FF4BF7C107" xml:lang="en"><title>Index</title><prolog><metadata><keywords/></metadata></prolog><conbody>
       
    13 <p>Messaging Server maintains an index entry in memory. A copy of the index
       
    14 entry of all message types is stored in the SQL database, so that it can be
       
    15 restored in the event of a system reset or Messaging Server failure. </p>
       
    16 <p>Some fields only apply to particular types of entry (such as messages or
       
    17 services); other fields can be interpreted differently for different entry
       
    18 types. </p>
       
    19 <section id="GUID-10265557-F31B-50B3-A955-A548A5A78D7B"><title>Operating with
       
    20 the SQL database</title> <p>The SQL database is used to store each <xref href="GUID-5A23B804-2C06-3407-9D48-1BFB212D699F.dita"><apiname>TMsvEntry</apiname></xref> (index
       
    21 entry) as a row of an SQL table in the SQL database. It caches entries, and
       
    22 maintains the most recently accessed entries in the RAM. Entries are cached
       
    23 in the RAM, and are loaded only when required. The RAM usage is controlled
       
    24 by emptying the oldest entry in the cache when it is full. For more information
       
    25 on caching, see <xref href="GUID-2FAB8281-569A-52BE-8BC8-A2D378068706.dita">Caching</xref>.
       
    26 The following illustration shows the architecture of the Message Server with
       
    27 the SQL database. </p> <fig id="GUID-57F87249-8F4F-59B4-902C-2A577A120F1A">
       
    28 <title>              Message Server architecture with the SQL database   
       
    29         </title>
       
    30 <image href="GUID-38089CC3-D969-5501-9FDA-BB0369D5D6A9_d0e283948_href.png" placement="inline"/>
       
    31 </fig><note> Write operations like updating, creating and deleting entries
       
    32 require disk operation to retrieve <xref href="GUID-5A23B804-2C06-3407-9D48-1BFB212D699F.dita"><apiname>TMsvEntry</apiname></xref> from database,
       
    33 because the entry cache is always in synchronisation with the corresponding
       
    34 entry in the database.</note> <p><b>Advantages</b> </p> <p>The following are
       
    35 the advantages of using the SQL database to store index entries: </p> <ul>
       
    36 <li id="GUID-49050952-7EB4-52A9-BEB3-0D1F467BFD42"><p>Reduces the amount of
       
    37 RAM used by messaging, as the message the index file is not used. </p> </li>
       
    38 <li id="GUID-AE0A5FA5-4588-5C28-A261-8ADD8917D56B"><p>Enables more messages
       
    39 to be stored on the device, as the number of messages stored is not restricted
       
    40 to the amount of RAM available to store the message index file. </p> </li>
       
    41 <li id="GUID-565D30B2-9249-5C9D-9DFD-B67C83BFAC35"><p>Enables controlled usage
       
    42 of RAM, as index entries are loaded on a need basis. </p> </li>
       
    43 <li id="GUID-E5CC0C68-A23F-5F99-BFBB-1AD1A3775454"><p>Eliminates the possibility
       
    44 of the message index file getting damaged and messages stored on the device
       
    45 getting deleted. </p> </li>
       
    46 <li id="GUID-148420E8-C23D-5678-8870-B8AA1CD8ED15"><p>Provides advanced search
       
    47 and sort capabilities for searching messages. </p> </li>
       
    48 <li id="GUID-0E1A2485-A90C-565B-B927-487EE3FB7E4C"><p>Accesses and manages
       
    49 message entries on one or more drives at the same time. </p> </li>
       
    50 </ul> </section>
       
    51 <section id="GUID-887B217A-0344-5764-800A-CD31481B1493"><title>Index fields</title> <p>The
       
    52 following information is stored for each index entry. Some fields only apply
       
    53 to particular types of entry, such as, messages or services; other fields
       
    54 can be interpreted differently for different entry types. </p> <table id="GUID-B0A760AE-DD82-56E5-A826-7AA0D4F522CD">
       
    55 <tgroup cols="2"><colspec colname="col0"/><colspec colname="col1"/>
       
    56 <tbody>
       
    57 <row>
       
    58 <entry><p>Attachment flag </p> </entry>
       
    59 <entry><p>Indicates that the message has an attachment </p> </entry>
       
    60 </row>
       
    61 <row>
       
    62 <entry><p>BIO </p> </entry>
       
    63 <entry><p><xref href="GUID-17DE7D55-00C9-5D40-8AE4-39BDB20FCC5B.dita">BIO message</xref> type </p> </entry>
       
    64 </row>
       
    65 <row>
       
    66 <entry><p>Complete flag </p> </entry>
       
    67 <entry><p>Indicates that the message is complete (for example download has
       
    68 completed. </p> </entry>
       
    69 </row>
       
    70 <row>
       
    71 <entry><p>Connected flag </p> </entry>
       
    72 <entry><p>For a service: indicates whether it is currently connected to a
       
    73 remote server </p> </entry>
       
    74 </row>
       
    75 <row>
       
    76 <entry><p>Deleted flag </p> </entry>
       
    77 <entry><p>Indicates that the entry has been deleted. The entry is not removed
       
    78 until any PC synchronisation tools have been informed of the deletion. </p> </entry>
       
    79 </row>
       
    80 <row>
       
    81 <entry><p>Description </p> </entry>
       
    82 <entry><p>A text string, usually giving the subject of the message </p> </entry>
       
    83 </row>
       
    84 <row>
       
    85 <entry><p>Details </p> </entry>
       
    86 <entry><p>A text string, as follows: </p> <p>Message: For received messages,
       
    87 this is the sender; for outgoing messages, it is the recipient </p> <p>Attachment:
       
    88 The name of the attachment </p> <p>Folder: The name of the folder </p> <p>Service:
       
    89 The name of the service </p> </entry>
       
    90 </row>
       
    91 <row>
       
    92 <entry><p>Error </p> </entry>
       
    93 <entry><p>A system-wide or MTM-specific error code </p> </entry>
       
    94 </row>
       
    95 <row>
       
    96 <entry><p>Flag </p> </entry>
       
    97 <entry><p>Use </p> </entry>
       
    98 </row>
       
    99 <row>
       
   100 <entry><p>Failed flag </p> </entry>
       
   101 <entry><p>For an outgoing message: indicates that sending failed </p> </entry>
       
   102 </row>
       
   103 <row>
       
   104 <entry><p>Identifier </p> </entry>
       
   105 <entry><p>An integer that uniquely identifies the entry in the Index </p> </entry>
       
   106 </row>
       
   107 <row>
       
   108 <entry><p>In preparation </p> </entry>
       
   109 <entry><p>Entry deleted if server restarts </p> </entry>
       
   110 </row>
       
   111 <row>
       
   112 <entry><p>MTM </p> </entry>
       
   113 <entry><p>A unique identifier specifying the MTM associated with the entry </p> </entry>
       
   114 </row>
       
   115 <row>
       
   116 <entry><p>MTM Data </p> </entry>
       
   117 <entry><p>Three integer fields for MTM-specific use </p> </entry>
       
   118 </row>
       
   119 <row>
       
   120 <entry><p>Multiple Recipients flag </p> </entry>
       
   121 <entry><p>Indicates the message has multiple recipients that require separate
       
   122 transmissions (for example, a fax going to two people) </p> </entry>
       
   123 </row>
       
   124 <row>
       
   125 <entry><p>New flag </p> </entry>
       
   126 <entry><p>Indicates a new message in a folder </p> </entry>
       
   127 </row>
       
   128 <row>
       
   129 <entry><p>Owner flag </p> </entry>
       
   130 <entry><p>Indicates that the entry owns other entries (that it is a parent) </p> </entry>
       
   131 </row>
       
   132 <row>
       
   133 <entry><p>Parent </p> </entry>
       
   134 <entry><p>An integer giving the identifier of the entry’s parent </p> </entry>
       
   135 </row>
       
   136 <row>
       
   137 <entry><p>Priority </p> </entry>
       
   138 <entry><p>An integer giving the message priority </p> </entry>
       
   139 </row>
       
   140 <row>
       
   141 <entry><p>Read flag </p> </entry>
       
   142 <entry><p>Indicates that a message has been read </p> </entry>
       
   143 </row>
       
   144 <row>
       
   145 <entry><p>Read Only flag </p> </entry>
       
   146 <entry><p>Indicates that the entry is read-only </p> </entry>
       
   147 </row>
       
   148 <row>
       
   149 <entry><p>Related folder </p> </entry>
       
   150 <entry><p>The identifier of a target folder for copying or moving entries </p> </entry>
       
   151 </row>
       
   152 <row>
       
   153 <entry><p>Sending state </p> </entry>
       
   154 <entry><p>Describes the state the message is in, for example "Sending", "Failed"
       
   155 and "Sent" </p> </entry>
       
   156 </row>
       
   157 <row>
       
   158 <entry><p>Service </p> </entry>
       
   159 <entry><p>The identifier of the service by which the message is to be sent
       
   160 or from which it was received </p> </entry>
       
   161 </row>
       
   162 <row>
       
   163 <entry><p>Size </p> </entry>
       
   164 <entry><p>An integer giving the size of the message </p> </entry>
       
   165 </row>
       
   166 <row>
       
   167 <entry><p>Standard Folder flag </p> </entry>
       
   168 <entry><p>Identifies standard folders so that they can be properly sorted
       
   169 and stops them being changed/deleted </p> </entry>
       
   170 </row>
       
   171 <row>
       
   172 <entry><p>Time </p> </entry>
       
   173 <entry><p>The time when the message was last edited, sent, or received. Includes
       
   174 date. </p> </entry>
       
   175 </row>
       
   176 <row>
       
   177 <entry><p>Type </p> </entry>
       
   178 <entry><p>A unique identifier giving the type (service, folder, message, and
       
   179 attachment) of the entry </p> </entry>
       
   180 </row>
       
   181 <row>
       
   182 <entry><p>Visibility flag </p> </entry>
       
   183 <entry><p>Indicates the intended visibility of the entry to users of message
       
   184 client applications </p> </entry>
       
   185 </row>
       
   186 </tbody>
       
   187 </tgroup>
       
   188 </table> </section>
       
   189 </conbody></concept>