CN100550010C - Be used for application program and system and method based on the storage platform interface of item - Google Patents

Be used for application program and system and method based on the storage platform interface of item Download PDF

Info

Publication number
CN100550010C
CN100550010C CNB038269414A CN03826941A CN100550010C CN 100550010 C CN100550010 C CN 100550010C CN B038269414 A CNB038269414 A CN B038269414A CN 03826941 A CN03826941 A CN 03826941A CN 100550010 C CN100550010 C CN 100550010C
Authority
CN
China
Prior art keywords
project
type
relation
file
storage platform
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Fee Related
Application number
CNB038269414A
Other languages
Chinese (zh)
Other versions
CN1820266A (en
Inventor
W·C·吴
M·E·迪姆
E·G·谢帕德
方黎江
J·李
M·B·泰勒
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Microsoft Technology Licensing LLC
Original Assignee
Microsoft Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Microsoft Corp filed Critical Microsoft Corp
Publication of CN1820266A publication Critical patent/CN1820266A/en
Application granted granted Critical
Publication of CN100550010C publication Critical patent/CN100550010C/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F17/00Digital computing or data processing equipment or methods, specially adapted for specific functions
    • G06F17/40Data acquisition and logging

Abstract

Various embodiments of the present invention are at a kind of storage platform (Figure 20), comprise: data storage, wherein the data of Chu Cuning are according to project, element and relation (Figure 20,2014) define, wherein, project is can be stored in the data cell in the data storage and comprise one or more elements, and element is the type (Figure 20 that comprises one or more fields, 2016) example, and relation is the link between at least two projects; The modal sets (Figure 20,2014) of definition items of different types, element and relation (Figure 20,2016); And application programming interface (Figure 20,350a, 250b or 350c), it comprises a class (Figure 20,2008) to each of the disparity items, element and the relation that define in the modal sets.Data also can be stored in the data storage with the form to the expansion of off-the-shelf item type, and wherein, application programming interface comprises a class (Figure 20,2006) to each different projects expansion.

Description

Be used for application program and system and method based on the storage platform interface of item
Cross reference
The application's theme relates to invention disclosed in the application of following common transfer: submit to simultaneously with the application, title is the U.S. Patent application ( application number is unallocated ) ( agent docket MSFT-1748 ) of " SYSTEMS AND METHODS FOR REPRESENTING UNITS OFINFORMATION MANAGEABLE BY A HARDWARE/SOFTWARE INTERFACESYSTEM BUT INDEPENDENT OF PHYSICAL REPRESENTATION ( be used to represent can be by the hardware/software interface system management but be independent of the system and method for the message unit of physical representation ) "; Submit to simultaneously with the application, title is the U.S. Patent application (application number is unallocated) (agent docket MSFT-1749) of " SYSTEMS AND METHODS FOR SEPARATING UNITS OF INFORMATIONMANAGEABLE BY A HARDWARE/SOFTWARE INTERFACE SYSTEM FROMTHEIR PHYSICAL ORGANIZATION (be used for can be separated with its physical organization by hardware/software interface system information of managing unit system and method) "; Submit to simultaneously with the application, title is the U.S. Patent application (application number is unallocated) (agent docket MSFT-1750) of " SYSTEMS AND METHODS FORTHE IMPLEMENTATION OF A BASE SCHEMA FOR ORGANIZING UNITS OFINFORMATION MANAGEABLE BY A HARDWARE/SOFTWARE INTERFACESYSTEM (be used for to realize be used for tissue can by the system and method for the basic model of the information unit of hardware/software interface system management) "; Submit to simultaneously with the application, title is the U.S. Patent application (application number is unallocated) (agent docket MSFT-1751) of " SYSTEMS AND METHODS FOR THEIMPLEMENTATION OF A CORE SCHEMA FOR PROVIDING A TOP-LEVELSTRUCTURE FOR ORGANIZING UNITS OF INFORMATION MANAGEABLE BYA HARDWARE/SOFTWARE INTERFACE SYSTEM (be used to realize to be provided for to organize can by the system and method for the core schema of the top level structure of hardware/software interface system information of managing unit) "; And that the application submits to simultaneously, title is the U.S. Patent application (application number is unallocated) (agent docket MSFT-1752) of " SYSTEMS AND METHOD FOR REPRESENTINGRELATIONSHIPSBETWEEN UNITS OF INFORMATION MANAGEABLE BY AHARDWARE/SOFTWAREINTERFACE SYSTEM (be used to represent can by the system and method for the relation between the hardware/software interface system information of managing unit) "; Submit to simultaneously with the application, title is the U.S. Patent application (application number is unallocated) (agent docket MSFT-2734) of " STORAGE PLATFORMFOR ORGANIZING, the SEARCHING AND SHARING DATA storage platform of search and shared data (be used to organize) "; And submit to simultaneously with the application, title is the U.S. Patent application (application number is unallocated) (agent docket MSFT-2735) of " SYSTEMS AND METHODS FOR DATAMODELING IN AN ITEM-BASED STORAGE PLATFORM (system and method that is used for the data modeling of project-based storage platform) ".
Technical field
The present invention relates generally to the information storage and retrieval field, relate in particular to the active storage platform that is used in computerized system tissue, search and shared data of different types.
Background of invention
In last decade, the capacity of single disc is annual to increase about percent 70 (70%).The calculated to a nicety dramatic increase of CPU (central processing unit) (CPU) ability in several years in the past of mole (Moore) law.Wiredly provide quantitatively huge being connected and bandwidth with wireless technology.Suppose that current trend continues, general laptop computer will have the storage of about terabyte (TB) and comprise millions of files in the several years, and the driver of 500,000,000,000 bytes (500GB) becomes common.
The consumer uses their computing machine to be mainly used in communication and organize personal information, no matter they are the data or the medium as digital music or photo of traditional personal information manager (PIM) style.The ability of the amount of digital content and storage raw bytes increases in large quantities; Yet the consumer can be used for organizing and the method for unifying these data does not but catch up with paces.The knowledge worker spends that the plenty of time manages and shared information, and some studies estimation, and the knowledge worker spends the time of 15-25% in the activity relevant with invalid information.Research is estimated in addition, and typical knowledge worker spends 2.5 hours search information every day approximately.
What a large amount of time of developer and infotech (IT) department investment and money made up themselves is used for the abstract data storage of public storage, to represent as items such as people, place, Time And Events.This not only causes the work of repetition, also forms the isolated island of public data, does not have the mechanism of common search or shared those data.How many address books only consider has now on the computing machine of operation Microsoft Windows operating system.Many application programs as email client and Personal Finance program keep address book separately, and have only seldom shared between the address-book data application program that each such program is safeguarded respectively.Thereby financial procedure (as MicrosoftMoney) is not shared payer's address with the address of safeguarding in e-mail contacts file (as the contacts folder among the Microsoft Outlook).Really, many users have a plurality of equipment, should be logically between these equipment and between being included in as the various additive sources of the cell-phone telephone number of commerce services such as MSN and AOL their personal data synchronously; Yet the cooperation major part of shared document finishes by document is attached to email message-and this is manual and poor efficiency.
The classic method that a reason that lacks cooperation is the information in the organize computer systems concentrates on the system (" file system ") of use based on file-file-catalogue, comes abstract in the hierarchy of categories of a plurality of file organizations to file based on the physical organization of the storage medium that is used for storage file.But the Multics operating system in nineteen sixty for exploitation is considered to be in and uses file, file and catalogue to manage the pioneer of storage data units on the operating system grade.Particularly, Multics uses symbolic address (thereby notion of introducing file path) in the hierarchy of file, and wherein the physical address of file is opaque to user (application program and final user).This file system gives no thought to the file layout of any single file, and the pass that reaches hereof between the file ties up to (that is, different with the position of file in the hierarchy) that are considered on the operating system grade have nothing to do.Because the appearance of Multics, storable data are organized into file, file and catalogue on operating system grade.These files generally comprise the file hierarchy itself (" catalogue ") that is placed on by in the specific file of file system maintenance.This directory further is safeguarded the tabulation corresponding to the clauses and subclauses of all other files in this catalogue and the node location of those files in hierarchy (referring to file here).This is a state nearly 40 years in this area.
Yet, though the reasonable representation of the information in the physical store system that resides in computing machine is provided, but file system is the abstract of physical store system, thereby what (having context, feature and and the unit of the relation of other unit) utilization of file need handle and operating system provides indirect (explanation) between what (file, file and catalogue) layer the user.As a result, user (application program and/or final user) have to force message unit is put into file system structure, though do like this be poor efficiency, inconsistent or undesirable.In addition, existing file system is known little about it about the structure of the data of storing in each file, and therefore, most of information keep sealing hereof, can only be write the application access (with understanding) of those data.Therefore, lack the pattern description of information and the mechanism of management information, cause forming the first in first out memory buffer (silo) of data, have only less data between each first in first out memory buffer, to share.For example, many personal computers (PC) user has storage different more than 5, and they comprise about they submit mutual people's information-as Outlook contact person, online account address, Windows address book, Quicken payee and instant message (IM) partner list-because constituent act proposes important challenge to these pc users at certain one deck.Because most of existing file system utilize nested file metaphor to come constituent act and file, therefore when quantity of documents increases, become very surprising for keeping the necessary effort of flexible and effective enterprise schema.In these cases, the multiple classifition with single file is very useful; Yet use the hard and soft link in the existing file system to be trouble and to be difficult to safeguard.
Past has been made the shortcoming that some unsuccessful trials overcome file system.Some have related in attempting before these certain storer that uses content addressable and provide and can rather than visit the mechanism of data by physical address by content.Yet, these effort are proved to be unsuccessful, though thereby the storer of content addressable is to being proved to be useful by using as the small-scale of equipment such as high-speed cache and Memory Management Unit, but still impossible owing to a variety of causes to the extensive use as equipment such as physical storage mediums, therefore such solution exists seldom or never.Made other trial of using OODB Object Oriented Data Base (OODB) system, though but these trials have the feature of strong database, and good non-representation of file, but handling aspect the representation of file ineffectively, can not reappear on the hardware/software interface system level speed, efficient and simplicity based on the file and the file of hierarchy.Use other trial of SmallTalk (with other derived method) being proved to be quite effective aspect processing file and the non-representation of file such as attempting, organize and utilize the necessary database feature of the relation that exists effectively but lack between various data files, therefore the whole validity of the sort of system is unacceptable.Use BeOS (with other such operating system research) although another trial can be competent at when suitably representing file and provide some data necessary Al Kut to levy again, be proved to be not enough in the expression of handling non-file, this is the same core shortcoming of traditional file systems.
Database technology is another professional domain that has similar challenge.For example, though the relevant database model has been obtained very big coml success, in fact stand alone software retail trader (ISV) has generally used available function sub-fraction in the relevant database software product (as Microsoft SQL Server).On the contrary, the great majority of application program and such product are the form with simple " gets " and " puts " alternately.Though this is had some reasons of understanding easily (as platform or database unknowable), the reason of a commonly overlooked key be database there is no need to provide primary commercial application program retail trader to need really accurately abstract.For example, though real world has the notion (and " line item " of the embedding of order conduct project and project itself wherein) as " client " or " projects " such as " orders ", and relevant database is only being talked about aspect table and the row.As a result, though application program may wish to have consistance, locking, safety and/or trigger on project level aspect (only listing), database only provides these features on table/row grade usually.Although also can work finely if each project is mapped to the single row of certain table of database, but under situation with the order of a plurality of line items, exist a project in fact will be mapped to the reason of a plurality of tables, and in the case, single system R can not provide correct abstract definitely.Therefore, application program must be at the top layer construction logic of database to provide these abstract substantially.In other words, the fundamental relation model does not provide enough platforms of the storage data of developing advanced application thereon easily, because the fundamental relation model need be between application program and storage system indirect layer, wherein only in the application program of some situation, can see the semantic structure of data.Although some database retail trader just is being building up to Premium Features in their product and (as is providing the object relationship ability, new organize models etc.), so far which still not having, the total solution that needs is provided, and wherein real total solution is the solution of the data model abstract (as " project ", " expansion ", " relation " etc.) that provides usefulness for useful territory abstract (as " individual ", " position ", " incident " etc.).
Consider the above-mentioned shortcoming in available data storage and the database technology, need a kind of new storage platform, a kind of improved ability is provided for it so that all types of data in tissue, search and the shared computer system-a kind of storage platform, it is expanded outside existing file system and Database Systems and has enlarged data platform, and is designed to store all types of data.The present invention satisfies this demand.
Summary of the invention
Below general introduction provides the summary to each side of the present invention.This summary is not the detailed description that aims to provide all importances of the present invention, is not intended to define scope of the present invention yet.On the contrary, this general introduction is intended to the introduction of doing the following detailed description and accompanying drawing.
The present invention is directed to a kind ofly be used to organize, the storage platform of search and shared data.Storage platform of the present invention expands and has enlarged the notion of data storage outside existing file system and Database Systems, and is designed to store all types of data, comprises structurized, non-structured or semi-structured data.
According to an aspect of of the present present invention, storage platform of the present invention is included in the data storage that realizes on the database engine.In various embodiments of the present invention, database engine comprises the relevant database engine with object relationship expansion.This data storage realize supporting data tissue, search, share, synchronously and the data model of security.Concrete data type is described in pattern, and the mechanism of a kind of mode of extension collection with definition new data type (being the subtype of the fundamental type that provided by pattern in essence) is provided this platform.A kind of synchronizing capacity helps at user or system's data sharing.The ability of similar file system is provided, and it allows the interoperability of this data storage and existing file system, and does not have the restriction of this traditional file systems.A kind ofly change the ability that follow-up mechanism provides the change of tracking data storage.This storage platform also comprises one group of application programming interfaces, and they make application program can visit the above-mentioned of this storage platform and have the ability, and can visit the data of describing in pattern.
According to another aspect of the present invention, the data model of realizing by this data storage according to project, element and contextual definition the unit of data storage.Project is the data cell that can store in data storage, and can comprise one or more elements and relation.Element is the example of type, comprises one or more fields (being also referred to as attribute herein).Relation is two links between the project.(as used herein, these and other specific term can be capitalized, so that they are separated from similar employed other term, yet, be not to be intended to treat with a certain discrimination the term capitalized for example " Item " and the same term during by capitalization, for example " item ", and should not suppose or hint this difference.)
According to another aspect of the present invention, a kind of computer system comprises a plurality of projects, but wherein each formation can be by the discrete canned data unit of hardware/software interface system manipulation; A plurality of project folders, they have constituted the institutional framework of described project; And the hardware/software interface system that is used to handle a plurality of projects, and wherein each project belongs at least one project folder, and can belong to an above project folder.
According to another aspect of the present invention, a kind of computer system comprises a plurality of projects, and wherein, each project constitutes can be by the discrete message unit of hardware/software interface system manipulation, and opposite with derivation from persistent storage, project or some item attribute value can dynamically be calculated.In other words, this hardware/software interface system does not require that project is stored, and support some operation, such as the ability of enumerating current Item Sets, or the project that provides at the identifier on the storage platform (describing in the joint of application programming interface or API and more completely describing) and the ability of search terms-for example, project can be cellular current location, or the temperature of reading from temperature sensor.
According to another aspect of the present invention, a kind of hardware/software interface system that is used for computer system comprises that also wherein said hardware/software interface system is handled a plurality of projects by the project of a plurality of relation interconnection of this hardware/software interface system management.According to another aspect of the present invention, a kind of hardware/software interface system that is used for computer system, wherein said hardware/software interface system are handled a plurality of discrete messages unit with the attribute that can be understood by described hardware/software interface system.According to another aspect of the present invention, a kind of hardware/software interface system that is used for computer system comprises core schema, so that define that described hardware/software interface system is appreciated that and can be with a kind of predetermined one group of core project directly handling with predictable mode.According to another aspect of the present invention, a kind of method that is used for handling a plurality of discrete messages unit (" project ") of the hardware/software interface system that is used for computer system is disclosed, described method comprises described project and the interconnection of a plurality of relation, and manage described relation on the hardware/software interface system level.
According to another feature of the present invention, the API of this storage platform provides data class for each project, project expansion and the relation of storage platform pattern centralized definition.In addition, this application programming interface provides a framing class, and they have defined one group of public behavior for described data class, and provides basic programming model with data class for storage platform API.According to another feature of the present invention, this storage platform API provides the interrogation model of simplifying, its mode so that the application programmer is kept apart from the details of the query language of underlying database engine makes the application programmer can form the inquiry based on the various attributes of the project in the data storage.According to the another aspect of storage platform API of the present invention, this API collects the change of project being made by application program, and then they is organized in the required correct renewal of the database engine (or storage engines of any kind of) of realizing this data storage.This makes the application programmer to change project in storer, and leaves the complicacy that data storage is upgraded for API.
By its common storage basis with by the data of medelling, storage platform of the present invention can be made more effective application development for consumer, Knowledge Worker and enterprise.It provides abundant and extendible application programming interface, this interface not only make in its data model intrinsic ability can use, but also comprise and expanded existing file system and database accessing method.
By reading following the detailed description and the accompanying drawings of the present invention, can know other features and advantages of the present invention.
The accompanying drawing summary
When reading, can understand top general introduction and following detailed description of the present invention better in conjunction with appended accompanying drawing.For explaining purpose of the present invention, the exemplary embodiment of various aspects of the present invention shown in the drawings; Yet, the invention is not restricted to disclosed concrete grammar and means.In the accompanying drawings:
Fig. 1 is that represent wherein can be in conjunction with the block diagram of the computer system of each side of the present invention;
Fig. 2 shows the block diagram of the computer system that is divided into 3 component groups: nextport hardware component NextPort, hardware/software system interface module and application component;
Fig. 2 A shows the traditional hierarchy based on tree that is used for being grouped into based on the file in the file in the catalogue of the operating system of file;
Fig. 3 is the block diagram that illustrates according to storage platform of the present invention;
Fig. 4 shows the structural relation between project in the various embodiments of the present invention, project folder and the classification;
Fig. 5 A shows the block diagram of the structure of project;
Fig. 5 B is the block diagram of complex properties type that the project of Fig. 5 A is shown;
Fig. 5 C is the block diagram that " Location (position) " project is shown, and wherein further describes (listing clearly) its complicated type;
Fig. 6 A shows the project as the subtype of the project that finds in the basic schema;
Fig. 6 B shows the block diagram of the subtype project of Fig. 6 A, has wherein listed the type (except its direct attribute) of its succession clearly;
Fig. 7 shows the block diagram of basic model, and this basic model comprises two top layer class type, i.e. Item (project) and PropertyBase (attribute base), and the additional basis mode type from wherein deriving;
Fig. 8 A is the block diagram that the project in the core schema is shown;
Fig. 8 B is the block diagram that the attribute type in the core schema is shown;
Fig. 9 is the block diagram that the interconnected relationship between project folder, its member's project and project folder and its member's project is shown;
Figure 10 shows the block diagram of the interconnected relationship between classification (itself also is a project), its member's project and classification and the member's project thereof;
Figure 11 is the figure that illustrates according to the reference type level of the data model of storage platform of the present invention;
Figure 12 is that illustrating according to one embodiment of the present of invention relation is the figure how to be classified;
Figure 13 is the figure that illustrates according to the informing mechanism of one embodiment of the present of invention;
Figure 14 illustrates wherein two affairs are all inserted figure from the example of new record to same B tree;
The data that Figure 15 shows according to one embodiment of the present of invention change testing process;
Figure 16 shows exemplary directory tree;
Figure 17 shows file according to the wherein existing file system based on catalogue of an aspect of of the present present invention and is moved to example in this storage platform data storage;
Figure 18 shows the notion according to an aspect of of the present present invention include file folder;
Figure 19 shows the basic architecture of storage platform API;
Figure 20 has schematically shown each assembly of storage platform API stack;
Figure 21 A and 21B are the diagrammatic representations of example contacts pattern (project and element);
Framework when Figure 22 shows according to the operation of the storage platform API of an aspect of of the present present invention;
Figure 23 shows the execution according to " FindAll " operation of one embodiment of the present of invention;
Figure 24 shows the process that is used for generating from the storage platform pattern storage platform API class according to an aspect of of the present present invention;
Figure 25 show according to another aspect of the present invention File (file) API based on pattern;
Figure 26 illustrates the synoptic diagram that is used for the access mask form of data security purpose according to one embodiment of the present of invention;
Figure 27 (a) and (b), (c) have provided a new safety zone of protection similarly that marks off in the existing safety zone according to the embodiment of an aspect of of the present present invention;
Figure 28 is the synoptic diagram that illustrates according to the notion of the project search view of the embodiment of an aspect of of the present present invention;
Figure 29 is the synoptic diagram that illustrates according to the exemplary items level of one embodiment of the present of invention;
Detailed description of the Invention
Catalogue
A. example calculation environment ... ... ... ... ... ... ... ... ... ... .16
B. traditional storage based on file ... ... ... ... ... ... ... ... ... .19
II. be used to organize, the new storage platform of search and shared data ... ... ... ... ... ... ..20
A. vocabulary ... ... ... ... ... ... ... ... ... ... ... 20
B. storage platform is summarized ... ... ... ... ... ... ... ... ... ... 21
C. data model ... ... ... ... ... ... ... ... ... ... ... .22
1. project ... ... ... ... ... ... ... ... ... ... ... ..23
2. project label ... ... ... ... ... ... ... ... ... ... ... .26
A) project is quoted ... ... ... ... ... ... ... ... ... ... ... .26
(1)ItemIDReference........................................................26
(2)ItemPathReference......................................................26
B) reference type hierarchy ... ... ... ... ... ... ... ... ... ..27
3. project folder and classification ... ... ... ... ... ... ... ... ... ..27
4. pattern ... ... ... ... ... ... ... ... ... ... ... ..28
A) basic schema ... ... ... ... ... ... ... ... ... ... ... .28
B) core schema ... ... ... ... ... ... ... ... ... ... ... .29
5. concern ... ... ... ... ... ... ... ... ... ... ... ..30
A) relation statement ... ... ... ... ... ... ... ... ... ... ... .31
B) hold relation ... ... ... ... ... ... ... ... ... ... ... .32
C) embed relation ... ... ... ... ... ... ... ... ... ... ... .33
D) adduction relationship ... ... ... ... ... ... ... ... ... ... ... .34
E) rule and constraint ... ... ... ... ... ... ... ... ... ... ..34
F) Guan Xi ordering ... ... ... ... ... ... ... ... ... ... ..34
6. extensibility ... ... ... ... ... ... ... ... ... ... ... .38
A) project expansion ... ... ... ... ... ... ... ... ... ... ... .39
B) expansion NestedElement type ... ... ... ... ... ... ... ... ... 42
D. database engine ... ... ... ... ... ... ... ... ... ... ..43
1. use the data storage of UDT to realize ... ... ... ... ... ... ... ... ... 44
2. project mapping ... ... ... ... ... ... ... ... ... ... ... .46
3. expansion mapping ... ... ... ... ... ... ... ... ... ... ... .47
4. nested element mapping ... ... ... ... ... ... ... ... ... ... 48
5. object identity ... ... ... ... ... ... ... ... ... ... ... .49
6.SQL object naming ... ... ... ... ... ... ... ... ... ... .49
7. row name ... ... ... ... ... ... ... ... ... ... ... 50
8. search view ... ... ... ... ... ... ... ... ... ... ... .50
A) project ... ... ... ... ... ... ... ... ... ... ... ..51
(1) master project search view ... ... ... ... ... ... ... ... ... ... 51
(2) typed project search view ... ... ... ... ... ... ... ... ... 51
B) project expansion ... ... ... ... ... ... ... ... ... ... ... .52
(1) main expanded search view ... ... ... ... ... ... ... ... ... ... 52
(2) typed expanded search view ... ... ... ... ... ... ... ... ... 52
C) nested element ... ... ... ... ... ... ... ... ... ... ..53
D) relation ... ... ... ... ... ... ... ... ... ... ... ..53
(1) primary relation search view ... ... ... ... ... ... ... ... ... ... 53
(2) relationship example search view ... ... ... ... ... ... ... ... ... .53
9. upgrade ... ... ... ... ... ... ... ... ... ... ... ..54
10. change and follow the tracks of and gravestone ... ... ... ... ... ... ... ... ... ... 55
A) change tracking ... ... ... ... ... ... ... ... ... ... ... .55
(1) change in " master " search view is followed the tracks of ... ... ... ... ... ... ... ... 55
(2) change in " typed " search view is followed the tracks of ... ... ... ... ... ... ... 56
B) gravestone ... ... ... ... ... ... ... ... ... ... ... ..57
(1) project gravestone ... ... ... ... ... ... ... ... ... ... ... 57
(2) expansion gravestone ... ... ... ... ... ... ... ... ... ... ... 57
(3) concern gravestone ... ... ... ... ... ... ... ... ... ... ... 58
(4) gravestone is removed ... ... ... ... ... ... ... ... ... ... ... 58
11. assistant API and function ... ... ... ... ... ... ... ... ... ... .58
A) function [System.Storage] .GetItem............................................59
B) function [System.Storage] .GetExtension.......................................59
C) function [System.Storage] .GetRelationship....................................59
12. metadata ... ... ... ... ... ... ... ... ... ... ... ..59
A) pattern metadata ... ... ... ... ... ... ... ... ... ... ..59
B) instance metadata ... ... ... ... ... ... ... ... ... ... ..59
E. security ... ... ... ... ... ... ... ... ... ... ... 59
1. summarize ... ... ... ... ... ... ... ... ... ... ... ..59
2. the detailed description of security model ... ... ... ... ... ... ... ... ... 64
A) security descriptor structure ... ... ... ... ... ... ... ... ... ... .64
(1) access mask form ... ... ... ... ... ... ... ... ... ... ..65
(2) generic access rights ... ... ... ... ... ... ... ... ... ... ..65
(3) standard access authority ... ... ... ... ... ... ... ... ... ... ..66
B) the special-purpose authority of project ... ... ... ... ... ... ... ... ... ... 66
(1) the special-purpose authority of file and directory object ... ... ... ... ... ... ... ... .66
(2)WinFSItemRead..........................................................67
(3)WinFSItemReadAttributes................................................68
(4)WinFSItemWriteAttributes...............................................68
(5)WinFSItemWrite.........................................................68
(6)WinFSItemAddLink.......................................................69
(7)WinFSItemDeleteLink....................................................69
(8) authority of delete items ... ... ... ... ... ... ... ... ... ... 69
(9) copy item purpose authority ... ... ... ... ... ... ... ... ... ... 70
(10) authority of mobile project ... ... ... ... ... ... ... ... ... ..70
(11) check the authority of the security strategy on the project ... ... ... ... ... ... ... ..70
The authority of the security strategy on (12) the change project ... ... ... ... ... ... ... ..70
(13) there is not the authority of direct equivalent ... ... ... ... ... ... ... ... ..71
3. realize ... ... ... ... ... ... ... ... ... ... ... ..71
A) in container, create new projects ... ... ... ... ... ... ... ... ... 71
B) add explicit ACL..................................................... ..71 to project
C) add the relation of holding to project ... ... ... ... ... ... ... ... ... 72
D) hold relation from deletion of items ... ... ... ... ... ... ... ... ... 72
E) the explicit ACL..................................................... 72 of deletion from project
F) revise the ACL...................................................73 that is associated with project
F. notify and change tracking ... ... ... ... ... ... ... ... ... ... .73
1. store the change incident ... ... ... ... ... ... ... ... ... ... 73
A) incident ... ... ... ... ... ... ... ... ... ... ... ..73
B) supervisory programme ... ... ... ... ... ... ... ... ... ... ... .74
2. change and follow the tracks of and the notice generting machanism ... ... ... ... ... ... ... ... ..75
A) change tracking ... ... ... ... ... ... ... ... ... ... ... .76
B) time mark management ... ... ... ... ... ... ... ... ... ... 77
C) data change detection-event detection ... ... ... ... ... ... ... ... ... 77
It is G. synchronous ... ... ... ... ... ... ... ... ... ... ... ..78
Storage platform to storage platform synchronously ... ... ... ... ... ... ... ... 78
A) synchronous (Sync) controlling application program ... ... ... ... ... ... ... ... ..79
B) pattern note ... ... ... ... ... ... ... ... ... ... ... .79
C) configuration synchronously ... ... ... ... ... ... ... ... ... ... ... .80
(1) community's file-mapping ... ... ... ... ... ... ... ... ... 81
(2) overview ... ... ... ... ... ... ... ... ... ... ... .82
(3) timetable ... ... ... ... ... ... ... ... ... ... ..82
D) conflict is handled ... ... ... ... ... ... ... ... ... ... .82
(1) collision detection ... ... ... ... ... ... ... ... ... ... 83
(a) based on the conflict of knowledge ... ... ... ... ... ... ... ... ... 83
(b) based on the conflict that retrains ... ... ... ... ... ... ... ... ... 83
(2) conflict is handled ... ... ... ... ... ... ... ... ... ... 84
(a) conflict is decomposed automatically ... ... ... ... ... ... ... ... ... ..84
(b) conflict log record ... ... ... ... ... ... ... ... ... ..85
(c) conflict is checked and is decomposed ... ... ... ... ... ... ... ... ... 85
(d) propagation of the convergence of duplicate and conflict decomposition ... ... ... ... ... ... ... .85
To non-storage platform data storage synchronously ... ... ... ... ... ... ... .86
A) synchronous service ... ... ... ... ... ... ... ... ... ... .86
(1) change is enumerated ... ... ... ... ... ... ... ... ... ... 86
(2) change application ... ... ... ... ... ... ... ... ... ... 87
(3) conflict is decomposed ... ... ... ... ... ... ... ... ... ... 87
B) adapter is realized ... ... ... ... ... ... ... ... ... ... ..88
3. security ... ... ... ... ... ... ... ... ... ... ... 88
4. manageability ... ... ... ... ... ... ... ... ... ... .88
G. traditional file interoperability ... ... ... ... ... ... ... ... ... ..88
1. interoperability model ... ... ... ... ... ... ... ... ... ... 89
2. data storage feature ... ... ... ... ... ... ... ... ... ... 90
A) non-volume ... ... ... ... ... ... ... ... ... ... ... ..90
B) storage organization ... ... ... ... ... ... ... ... ... ... .90
C) do not transplant All Files ... ... ... ... ... ... ... ... ... .91
D) the NTFS name space of storage platform file is visited ... ... ... ... ... ... .91
E) Qi Wang name space/drive letter ... ... ... ... ... ... ... ..91
I. storage platform API..................................................... ... ..91
1. summarize ... ... ... ... ... ... ... ... ... ... ... ..92
2. name and scope ... ... ... ... ... ... ... ... ... ... ..92
3. storage platform API assembly ... ... ... ... ... ... ... ... ... 94
4. data class ... ... ... ... ... ... ... ... ... ... ... 94
5. framework when moving ... ... ... ... ... ... ... ... ... ... .101
Framework class when a) moving ... ... ... ... ... ... ... ... ... ..101
(1)ItemContext........................................................101
(2)ItemSearcher................................................102
(a) target type ... ... ... ... ... ... ... ... ... .102
(b) filtrator ... ... ... ... ... ... ... ... ... 102
(c) prepare search ... ... ... ... ... ... ... ... ... .103
(d) search option ... ... ... ... ... ... ... ... ... .103
(3) project result stream (" FindResult ") ... ... ... ... ... ... .104
B) operation in operation the time framework ... ... ... ... ... ... ... .105
C) public programming mode ... ... ... ... ... ... ... ... .106
(1) open and close the ItemContext object ... ... ... ... ... ... ..106
(2) object search ... ... ... ... ... ... ... ... ... .107
(a) search option ... ... ... ... ... ... ... ... ... .108
(b) FindOne and FindOnly...........................................108
(c) shortcut on the Searching I temContext ... ... ... ... ... ... 109
(d) according to ID or path searching ... ... ... ... ... ... ... ..109
(e) GetSearcher pattern ... ... ... ... ... ... ... ... 110
(3) updated stored ... ... ... ... ... ... ... ... ... .110
6. security ... ... ... ... ... ... ... ... ... .112
7. the support to concerning ... ... ... ... ... ... ... ... .112
A) primary relationship type ... ... ... ... ... ... ... ... .113
(1) Relationship class ... ... ... ... ... ... ... ... .113
(2) ItemReference class ... ... ... ... ... ... ... ... 114
(3) ItemIdReference class ... ... ... ... ... ... ... .114
(4) ItemPathReference class ... ... ... ... ... ... ... ..115
(5) RelationshipId structure ... ... ... ... ... ... ... 115
(6) VirtualRelationshipCollection class ... ... ... ... ... ..116
B) relationship type of Sheng Chenging ... ... ... ... ... ... ... ... ..117
(1) relationship type of Sheng Chenging ... ... ... ... ... ... ... ... .118
(2) RelationshipPrototype class ... ... ... ... ... ... .118
(3) RelationshipPrototpyeCollection class ... ... ... ... ... 119
C) concern support in the Item class ... ... ... ... ... ... ... .119
(1) Item class ... ... ... ... ... ... ... ... ... 119
(2) RelationshipCollection class ... ... ... ... ... ... 119
D) concern support in the search expression formula ... ... ... ... ... ... ... 120
(1) traverse relation from project ... ... ... ... ... ... ... ..120
(2) traverse project from relation ... ... ... ... ... ... ... ..120
(3) syntagmatic traversal ... ... ... ... ... ... ... .121
E) example of relation support is used ... ... ... ... ... ... ..121
(1) search relation ... ... ... ... ... ... ... ... ..121
(2) navigate to the source and target project from relation ... ... ... ... ... .122
(3) navigate to relation from source item ... ... ... ... ... ... .123
(4) create relation (and project) ... ... ... ... ... ... .124
(5) deletion relation (and project) ... ... ... ... ... ... .125
8. " expansion " storage platform API.....................................125
A) territory behavior ... ... ... ... ... ... ... ... ..126
B) increment behavior ... ... ... ... ... ... ... ... 126
C) as ISP's increment behavior ... ... ... ... ... ..127
9. framework when designing ... ... ... ... ... ... ... ... .128
10. inquiry form ... ... ... ... ... ... ... ... ..128
A) filtrator basis ... ... ... ... ... ... ... ... .129
B) coercion of type conversion ... ... ... ... ... ... ... ..130
C) filtrator sentence structure ... ... ... ... ... ... ... ... .130
11. remote control ... ... ... ... ... ... ... ... ... 131
A) this locality among the API/long-range transparency ... ... ... ... ... ... .131
B) storage platform of remote control realizes ... ... ... ... ... ... ..132
C) the non-storage platform storage of visit ... ... ... ... ... ... ..132
D) with the relation of DFS ... ... ... ... ... ... ... ... 132
E) with the relation of GXA/Indigo ... ... ... ... ... ... ..132
12. constraint ... ... ... ... ... ... ... ... ... 133
13. share ... ... ... ... ... ... ... ... ... 134
A) expression is shared ... ... ... ... ... ... ... ... 135
B) management is shared ... ... ... ... ... ... ... ... 135
C) visit is shared ... ... ... ... ... ... ... ... 135
D) property found ... ... ... ... ... ... ... ... 136
14.Find semanteme ... ... ... ... ... ... ... ... 136
15. storage platform Contacts API...................................136
A) summary of System.Storage.Contact ... ... ... ... ... .137
B) territory behavior ... ... ... ... ... ... ... ... ..137
16. storage platform File API.......................................138
A) introduce ... ... ... ... ... ... ... ... ... .138
(1) reflection NTFS volume in storage platform ... ... ... ... ... ... 139
(2) in the storage platform name space, create file and catalogue ... ... ... ..139
B) file mode ... ... ... ... ... ... ... ..140
C) summary of System.Storage.Files ... ... ... ... ..140
D) example code ... ... ... ... ... ... ... ..140
(1) open file and write to it ... ... ... ... ... ... 140
(2) use inquiry ... ... ... ... ... ... ... .141
E) territory behavior ... ... ... ... ... ... ... ... .141
J. sum up ... ... ... ... ... ... ... ... 141
I. foreword
Theme of the present invention is described with details, to satisfy legal requirement.Yet itself does not attempt to limit the scope of this patent this description.On the contrary, the present inventor imagines claimed theme and also can otherwise implement, and is similar to the described different step of this document or the combination of step to comprise in conjunction with other current with following technology.In addition, though term " step " can be used for meaning the different elements of the method that is adopted here, yet this term can not be interpreted as the certain order between implicit each step that is disclosed here, unless described the order of each step clearly.
A. example calculation environment
Many embodiment of the present invention can carry out on computers.Fig. 1 and following discussion aim to provide the concise and to the point description that wherein realizes suitable computing environment of the present invention.Though be not essential, aspects of the present invention can be with such as by describing in the context as the computer executable instructions of the program module carried out on the computing machine of client workstation or server.Generally speaking, program module comprises routine, program, object, assembly, data structure etc., and they are carried out particular task or realize particular abstract.In addition, the present invention can realize with other computer system configurations, comprises handheld device, multicomputer system, based on the system of microprocessor or programmable consumer electronics, network PC, minicomputer, large scale computer etc.The present invention can also realize in distributed computing environment that wherein task is by finishing by the teleprocessing equipment of communication network link.In distributed computing environment, program module can be arranged in the Local or Remote memory storage device.
As shown in Figure 1, the exemplary universal computing system comprises traditional personal computer 20 etc., and it comprises processing unit 21, system storage 22 and will comprise that the various system components of system storage are coupled to the system bus 23 of processing unit 21.System bus 23 can be some kinds bus-structured any, any the local bus that comprises memory bus or memory controller, peripheral bus and use various bus architectures.System storage comprises ROM (read-only memory) (ROM) 24 and random-access memory (ram) 25.Basic input/output 26 (BIOS) comprises as help the basic routine of transmission information between all elements at personal computer 20 when starting, and it is stored among the ROM 24.Personal computer 20 also can comprise the disc driver 28, read-write of hard disk drive 27, the read-write moveable magnetic disc 29 of the reading writing harddisk (not shown) CD drive 30 as the removable CD 31 of CDROM or other light medium.Hard disk drive 27, disc driver 28 and CD drive 30 are connected to system bus 23 by hard disk drive interface 32, disk drive interface 33 and CD drive interface 34 respectively.Driver and the computer-readable medium that is associated thereof provide the non-volatile memories of computer-readable instruction, data structure, program module and other data for personal computer 20.Though exemplary environments described herein adopts hard disk, moveable magnetic disc 29 and removable CD 31, but it will be appreciated by those skilled in the art that, but in the exemplary operation environment, also can use stored energy other type computer computer-readable recording medium, as magnetic tape cassette, flash card, digital video disc, Bernoulli magnetic tape cassette, random-access memory (ram), ROM (read-only memory) (ROM) etc. by the data of computer access.Similarly, example context also can comprise the surveillance equipment of many types, as temperature-sensitive and safety or fire alarm system, and other information source.
Some program modules can be stored among hard disk, disk 29, CD 31, ROM 24 or the RAM 25, comprise operating system 35, one or more application program 36, other program module 37 and routine data 38.The user can be input to personal computer 20 by ordering as input equipments such as keyboard 40 and pointing devices 42 with information.Other input equipment (not shown) can comprise microphone, operating rod, game mat, satellite dish, scanner etc.These and other input equipment normal open overcoupling is connected to processing unit 21 to the serial line interface 46 of system bus, but also can connect by other interface, as parallel port, game port or USB (universal serial bus) (USB).The display device of monitor 47 or other type also is connected to system bus 23 by the interface as video adapter 48.Except that monitor 47, personal computer generally includes as other peripheral output device (not shown) such as loudspeaker and printers.The example system of Fig. 1 also comprises host adapter 55, small computer system interface (SCSI) bus 56 and is connected to the External memory equipment 62 of SCSI bus 56.
Personal computer 20 can use logic as one or more remote computers of remote computer 49 and be connected in the network environment and operate.Remote computer 49 can be another personal computer, server, router, network PC, peer device or other common network node, and generally include above many or all elements that personal computer 20 is described, though memory storage device 50 only is shown in Fig. 1.The logic of drawing among Fig. 1 connects and comprises Local Area Network 51 and wide area network (WAN) 52.Such network environment is common in office, enterprise-wide. computer networks, Intranet and the Internet.
When using in the lan network environment, personal computer 20 is connected to LAN 51 by network interface or adapter 53.When using in the WAN network environment, personal computer 20 generally includes modulator-demodular unit 54 or is used for by setting up other device of communication as wide area networks such as the Internet 52.Built-in or external modulator-demodular unit 54 is connected to system bus 23 by serial port interface 46.In network environment, program module or its part of personal computer 20 descriptions can be stored in the remote memory storage device relatively.Be appreciated that it is exemplary that the network that illustrates connects, and can use other means of setting up communication link between computing machine.
Shown in the block diagram of Fig. 2, computer system 200 can be divided into three component groups roughly: nextport hardware component NextPort 202, hardware/software interface system component 204 and application component 206 (being also referred to as " nest " or " component software " here in some context).
Get back to Fig. 1, in each embodiment of computer system 200, nextport hardware component NextPort 202 can comprise CPU (central processing unit) (CPU) 21, storer (ROM 24 and RAM 25), basic input/output (BIOS) 26 and various I/O (I/O) equipment, as keyboard 40, mouse 42, monitor 47 and/or printer (not shown) etc.Nextport hardware component NextPort 202 comprises the basic physical basis structure of computer system 200.
Application component 206 comprises various software programs, includes but not limited to compiler, Database Systems, word processing program, commercial programs, video-game etc.Application program provides computer resource to be used to various users (machine, other computer system and/or final user) to deal with problems, provide the means of solution and deal with data.
Hardware/software interface system component 204 comprises (can only comprise in certain embodiments) operating system, and in most of the cases the latter itself comprises shell and kernel." operating system " is the separate procedure of taking on the intermediary between application program and computer hardware (OS).Hardware/software interface system component 204 also can comprise virtual machine manager (VMM), common statement Runtime Library (CLR) or its functional equivalent, Java Virtual Machine (JVM) or its functional equivalent or replace operating system or other component software except that operating system in computer system.The purpose of hardware/software interface system provides user's environment of executive utility therein.The target of any hardware/software interface system is to make computer system easy to use, and utilizes computer hardware with effective and efficient manner.
Hardware/software interface system generally is loaded into computer system when starting, and manages all application programs in computer system subsequently.Application program is by coming with hardware/software interface system mutual via application programming interfaces (API) request service.Some application program makes the final user can be by mutual as command language or graphic user interface user interfaces such as (GUI) and hardware/software interface system.
Hardware/software interface system is the various services of executive utility traditionally.In the multitask hardware/software interface system that a plurality of programs are moved simultaneously, hardware/software interface system determines which application program should with what time sort run, and how long allows for each being used journey before in turn switching to the Another Application program.Hardware/software interface system is also managed sharing of between a plurality of application programs internal storage, and handles the input and output that commute as additional hardware device such as hard disk, printer and dialing port.Hardware/software interface system also sends to the message about mode of operation and contingent any mistake each application program (arriving the final user in some cases).Hardware/software interface system also can descend pass the management of (as printing) of (offload) batch processing job, makes application program started can break away from this work and restarts other processing and/or operation.On the computing machine that parallel processing can be provided, hardware/software interface system is also managed partition program, makes it move on a plurality of processors simultaneously.
Hardware/software interface system shell (being called for short " shell " here) is the interactive end-user interface to hardware/software interface system.(shell is also referred to as " command interpreter ", or in operating system, be called " operating system shell ").Shell be can be directly by the skin of the hardware/software interface system of application program and/or visit to end user.Opposite with shell, kernel is an innermost layer direct and hardware/software interface system that nextport hardware component NextPort is mutual.
Be particularly useful for computerized system though can conceive many embodiment of the present invention, yet do not mean that in which in this document and to limit the invention to those embodiment.On the contrary, term used herein " computer system " is intended to comprise can storage and process information and/or can use any and all devices of the behavior or the execution of canned data opertaing device itself, and no matter whether those device, in essence are electronics, mechanical, logic or virtual.
B. traditional storage based on file
In current most computers system, " file " but be the unit of canned data, it can comprise hardware/software interface system and application program, data set etc.In all modern hardware/software interface system (Windows, Unix, Linux, MacOS, dummy machine system etc.), file is can be by basic discrete (can store and can retrieve) message unit of hardware/software interface system processing.File group is organized into " file " usually.In MicrosoftWindows, Macintosh OS and other hardware/software interface system, file is the set of the file that can be retrieved as single message unit, move and handle.These files and then be organized into are called the hierarchal arrangement based on tree of " catalogue " (going through in the back).In as Dos, z/OS and great majority other hardware/software interface system based on the operating system of Unix, term " catalogue " and/or " file " are used interchangeably, and early stage apple computer system (as Apple IIe) uses term " classification " to replace catalogue; Yet when here using, all these terms are regarded as synonym and are used interchangeably, and are intended to also to comprise quoting all other equivalent terms of hierarchical information storage organization and file and file components.
Traditionally, catalogue (catalogue that has another name called file) is based on the hierarchy of tree, and wherein file is combined into file, file and then the relative node location arrangement of pressing the formation directory tree.For example, shown in Fig. 2 A, basic document folder (or " root directory ") 212 based on the file system of DOS can comprise a plurality of files 214, its each can also comprise other file (as " sub-folder " of particular file folder) 216, and these each comprises other file 218, to infinity.Each of these files can have one or more files 220, though on the hardware/software interface system level, what common ground each file in the file does not have except their positions in tree-like hierarchy.Not strange, the physical organization of file organization having been reflected indirectly the typical storage medium (as hard disk, floppy disk, CD-ROM etc.) that is used to store these files to the method for file hierarchy.
Except that above-mentioned, each file be to its sub-folder and its file container-promptly, each file has its sub-folder and file.For example, when file is deleted by hardware/software interface system, the sub-folder and the file also deleted (sub-folder and the file that under the situation of each sub-folder, also recursively comprise it) of this document folder.Equally, each file is general only to be had by a file, though and file can be replicated and copy is positioned at different files, the copy of file itself is difference and separate unit, and it does not have directly with source document and is connected (not being reflected to wave file as the change to source document on the hardware/software interface system level).Therefore in this respect, file and file are " physics " in itself handle because file is similar to physical container, and file as different in these containers and independently physical element handle.
II. be used to organize, the new storage platform of search and shared data
The present invention is directed to be used to organize, the storage platform of search and shared data.Storage platform of the present invention is expanded outside the kind of file system discussed above and Database Systems and has been widened data platform, and is designed to store all types of data, comprises the data of the new model that is called project.
A. vocabulary
Reach the term that in claims, uses here following meaning arranged:
" project " is the unit of energy storage hardware/addressable information of software interface system, do not resemble simple files, and it is to have the object that is represented the basic attribute set of supporting jointly to all objects of final user by hardware/software interface system shell.Project also tool comprises the feature (going through below) that allows to introduce new attribute and relation to common attribute and the relation of supporting of all items type.
" operating system " is the separate procedure of taking on the intermediary between application program and the computer hardware (OS).In most of the cases, operating system comprises shell and kernel.
" hardware/software interface system " is the combination of software or hardware and software, and it plays a part the bottom hardware assembly and the interface between the application program of carrying out on the computer system of computer system.Hardware/software interface system generally includes (including only in certain embodiments) operating system.Hardware/software interface system can also comprise virtual machine manager (VMM), common statement Runtime Library (CLR) or its functional equivalent, Java Virtual Machine (JVM) or its functional equivalent or replacement operating system or other component software except that operating system in computer system.The purpose of hardware/software interface system provides the environment of user's energy executive utility.The target of any hardware/software interface system is to make computer system easy to use, and utilizes computer hardware with effective means.
B. storage platform is summarized
With reference to figure 3, be included in the data storage 302 that realizes on the database engine 314 according to storage platform 300 of the present invention.In one embodiment, database engine comprises the relevant database engine that has the object relationship expansion.In one embodiment, relevant database engine 3 14 comprises Microsoft SQL Server relevant database engine.
Data storage 302 realizes supporting the tissue, search of data, shared, synchronous and safe data model 304.Describe specific data type in as mode 3 40 isotypes, and storage platform 300 is provided for the instrument 346 that adopts these patterns and be used to expand these patterns, this describes in detail in the back.
The change follow-up mechanism 306 that realizes in data storage 302 provides the ability of the change of tracking data storage.Data storage 302 also provides security capabilities 308 and upgrading/degradation ability 310, and these all describe in detail later.Data storage 302 also provides one group of application programming interface 312, with the ability to other storage platform assembly that utilizes this storage platform and application program (as application program 350a, 350b and 350c) demonstrating data storage 302.
Storage platform of the present invention also comprises application programming interface (API) 322, makes as application program 350a, and application programs such as 350b and 350c can be visited all above-mentioned functions of storage platform and can visit the data of describing in pattern.Application program can be in conjunction with waiting other API to use storage platform API 322 as OLE DB API 324 and Microsoft Windows Win 32 API 326.
Storage platform 300 of the present invention can provide various services to application program, comprises the synchronous service 330 of being convenient to shared data between user or system.For example, synchronous service 330 allows and the interoperability that has with other data storage 340 of data storage 302 same format, and visit has the data storage 342 of other form.Storage platform 300 also provides data storage 302 and the file system ability as the interoperability of Windows new technology file system 318 systems such as existing file such as grade of allowing.
In some embodiment at least, storage platform 320 can also provide other ability to application program, data is worked and allows mutual with other system allowing.These abilities can be embodied as the form as Additional Services 328 such as Info Agent service 334 and notification service 332, and the form of other utility routine 336.
In some embodiment at least, storage platform is implemented with the hardware/software interface system of computer system, or forms its complete part.For example and unrestricted, storage platform of the present invention can be implemented with operating system, virtual machine manager (VMM), common statement Runtime Library (CLR) or its functional equivalent or Java Virtual Machine (JVM) or its functional equivalent, or forms its complete part.
By the data of its public storage basis and medelling, storage platform of the present invention makes consumer, knowledge worker and enterprise do more effectively to carry out the exploitation of application program.It provides abundant and extendible programming surf zone, not only can obtain ability intrinsic in its data model, can also comprise and expand existing file system and data bank access method.
In following description and in each accompanying drawing, storage platform 300 of the present invention can be called " WinFS ".Yet use this name to refer to that storage platform only is for convenience, does not attempt to make any restriction.
C. data model
The data storage 302 of storage platform 300 of the present invention realizes a kind of data model, and it is supported the tissue that resides in the data in the storage, search, shared, synchronous and safety.In data model of the present invention, " project " is the elementary cell of canned data.This data model provides a kind of mechanism, be used for statement project and project expansion, be used to set up the relation between the project and be used for the project organization to project folder and classification, these are with more abundant description hereinafter.
This data model depends on two primitive mechanism: type and relation.Type provides the structure of form of form of the example of domination type.Form is expressed as orderly group of attribute.Attribute is the name of the value or set of values of given type.For example, USPostalAddress (United States Post Office address) type has attribute Street (street), City (city), Zip (postcode), State (state), and wherein Street, City and State are the String types, and Zip is the Int32 type.Street can be many-valued (i.e. a class value), allows the address that the Street attribute is had value more than.Some primitive type that system definition can be used in other type structure comprises String (string), Binary (scale-of-two), Boolean (boolean), Int16 (16 integers), Int32 (32 integers), Int64 (64 integers), Single (single precision), Double (double precision), Byte (byte) DateTime (time on date), Decimal (decimal system) and GUID.Can use the type of any primitive type (have following note some restriction) or any structure to come the attribute of define styles.For example, Location (position) type can be defined as having attribute Coordinate (coordinate) and Address (address), and wherein the Address attribute is the above-mentioned type USPostalAddress.Attribute also can be essential or optional.
Relation can be declared and represent the mapping between the example set of two types.For example, the relation of stating can be arranged between Person (individual) type and Location type, be called LivesAt (living in), it determines where who lives in.Relation has title and two end points, i.e. source endpoint and target endpoint.Relation also can have the ordered set of attribute.Source endpoint and target endpoint all have title and type.For example, the LivesAt relation has the source of the Occupant (resident) that is called type Person and is called the target of the Dwelling (house) of type Location, and have attribute StartDate (from date) and EndDate (date of expiry) in addition, represent the time period of this resident living at this house.Notice that pass in time, the individual can live in a plurality of houses, and house can have a plurality of residents, be originally to be in relation so place the most probable place of StartDate and EndDate information.
Contextual definition by the mapping between the example of the type that provides as endpoint type constraint.For example the LivesAt relation can not be that wherein Automobile (automobile) is Occupant (resident's) a relation, because Automobile is not Person.
Data model allows the subtype-superclass type relation between define styles.Subtype-the superclass that is also referred to as fundamental type (BaseType) relation is the definition as follows of type relation, if type A is the fundamental type of type B, then situation must be that each example of B also is the example of A.The another kind of method of expressing is that each example that meets B also must meet A.For example, if the attribute Name (name) that A has the String type, and B has the attribute Age (age) of Int16 type, then draws, any example of B must have Name and Age concurrently.The hierarchy of type can be envisaged as the tree that has single superclass type on root.The branch of root provides first order subtype, and this grade branch provides second level subtype, and the rest may be inferred, up to end of blade (leaf-most) subtype that itself no longer has any subtype.Tree is not limited to the unified degree of depth, but can not comprise any loop.Given type can have zero or a plurality of subtype and zero or a superclass type.Given example can meet the superclass type an of type and the type at most.In other words, to the tree in arbitrary grade locate given example, this example can meet a subtype on this grade at most.
If the example of type must also be the example of the subtype of the type, then the type can be considered to abstract.
1. project
But project is the unit of canned data, does not resemble simple file, and it is the object with the common basic attribute set supported of all objects that is represented to final user or application program by storage platform.Project also has common attribute and the relation of supporting of all items type, comprises that permission as described below introduces the new attribute and the feature of relation.
Project is the object of common operation, as copying, delete, move, open, print, back up, recover, duplicate etc.Project is the unit that can be stored and retrieve, but and the form of ownership of the canned data of handling by storage platform exist as the attribute or the relation between the project of project, project, its each more go through below.
Project is intended to represent reality and data cell that understand easily, as Contacts (contact person), People (people), Services (service), Locations (position), (various types of) Documents (document) etc.Fig. 5 A is the block diagram that the structure of project is shown.The defective name of this project is " Location ".The qualified name of this project is " Core.Location ", and it shows that this project structure is defined by the project (core schema goes through below) of the particular type in core (Core) pattern.
The Location project has a plurality of attributes, comprises EAddress (e-mail address), MetropolitanRegion (urban place), Neighborhood (neighbour) and PostalAddress (postal address).The particular type attribute of each project is represented immediately following attribute-name, and is separated with attribute-name with colon (": ").On the right of type name, the quantity of the value that this attribute type is allowed represent that between square bracket (" [] ") wherein unspecified and/or unconfined quantity (" many ") represented in the asterisk (" * ") on colon (": ") the right." 1 " on colon the right shows maximum values.Zero (" 0 ") on the colon left side shows that this attribute is optional (void value fully)." 1 " on the colon left side shows to have a value (this attribute is necessary) at least.Neighborhood and MetropolitanRegin all are " nvarchar " types (or connection of equivalent type), and it is predefined data type or " simple types " (representing with lacking capitalization here).Yet EAddress and PostalAddress are respectively the define styles of type EAddress and PostalAddress or the attribute of " complicated type " (here with capitalization mark).Complicated type is from one or more simple data types and/or the type that derives from other complicated type.The complicated type of the attribute of project also constitutes " nested element ", because the details of complicated type is nested in the direct project to define its attribute, and the information appliance that relates to these complicated types has the project of these attributes to keep (in the border of this project, discussing as the back).These notions of type are that the crowd knows, and are understood by those skilled in the art easily.
Fig. 5 B is the block diagram that complex properties type PostalAddress and EAddress are shown.The project of PostalAddress attribute type defined attribute type PostalAddress can expect to have zero or a City (city) value, zero or a CountryCode (country code) value, zero or MailStop (mailbox code) value and any amount (zero to many) PostalAddress type or the like.In this way, defined the shape of the data of the particular community in the project.The EAddress attribute type is definition similarly as shown.Though can randomly use in this application here, the other method of complicated type is to use each attribute of each complicated type of wherein listing to draw this project in the expression Location project.Fig. 5 C is the block diagram that the Location project is shown, and further describes its complicated type therein.Yet should be appreciated that the another kind of Location project represents it just is same project to shown in Fig. 5 A in Fig. 5 C.Storage platform of the present invention also allows subtypeization, thereby an attribute type is another subtype (one of them Attribute class is inherited the attribute of another father's attribute type).
Be similar to but be different from attribute and their attribute type, Item (project) type of project inheritance ground expression its oneself, it also is the theme of subclassification.In other words, the subtype that to allow a project be another project of the storage platform among some embodiment of the present invention (thereby project is inherited the attribute of another father's project).In addition, to various embodiment of the present invention, each project is the subtype of " Item " item types, and the latter is first and the basic item types (basic schema also goes through in the back) that finds in basic schema.Fig. 6 A illustrates the subtype of a project (in this example for Location project) for the Item item types that finds in basic schema.In this figure, arrow represents that Location project (the same with all other projects) is the subtype of Item item types.Have as the Item item types of the elementary item of therefrom deriving all other projects some as ItemId important attribute and various time marks such as (item ids), thereby defined the standard attribute of all items in the operating system.In this figure, these attributes of Item item types are inherited by Location, thereby and become the attribute of Location.
The another kind of method of expression attribute from the Location project that the Item item types is inherited is to use each attribute from each attribute type of father's project of wherein listing to draw Location.Fig. 6 B is the block diagram that the Location project is shown, and wherein describes the type of its succession except its direct attribute.Should note and understand, this project is the same project shown in Fig. 5 A, though in this figure, Location illustrates with all its attributes, comprise direct attribute (shown in Ben Tu and Fig. 5 A) and inherited attribute (shown in this figure but not shown in Fig. 5 A) (and in Fig. 5 A, being that the subtype of Item item types is quoted these attributes) by the Location project is shown with arrow.
If project is an object independently, thereby deletion one project, and also all of delete items directly and the attribute of inheriting.Similarly, when retrieval one project, what receive is this project and all attributes (comprising the information that relates to its complex properties type) direct and succession thereof.Some embodiment of the present invention can make the people can be in the subclass of retrieval request attribute during specific project; Yet to many such embodiment acquiescences be when the retrieval to project provide all its directly and attributes of inheriting.In addition, the attribute of project also can be by adding new attribute to the existing attribute of the type of this project and expanded.These " expansions " are thereafter the true attributes of this project, and the subtype of this item types can automatically comprise extended attribute.
" border " of project represented by its attribute (comprising complex properties type, expansion etc.).The border of project is also illustrated in the restriction of the operation of carrying out on the project, comprise duplicate, delete, move, establishment etc.For example in some embodiment of the present invention, when duplicating project, all the elements within this item boundaries also are replicated.To each project, the border comprises following:
The item types of project, and, be any suitable sub-type information (information that promptly relates to father's item types) if this project is another purpose subtype (under the situation as some embodiment of the present invention of deriving from the single project of basic schema and item types at all items).If the original project that will duplicate is another purpose subtype, this copy also can be the subtype of this same project.
The complicated type attribute of project and expansion (if any).If original project has the attribute of complicated type (originally or expansion), copy also can have same complicated type.
The record of the project on " ownership ", that is, the project that this project (" having project ") has what other project (" directory items ") has tabulation.This in particular concerns the rule that the project folder that discusses fully below and all items that mentions below must belong to a project folder at least.In addition, about embedding project (following more discuss fully), the embedding project be considered to wherein to embed as duplicate, the part of the project of operation such as deletion.
2. project label
In overall project space, identify project uniquely with ItemID.The Base.Item type definition store the field ItemID of the type GUID of this project identity.A project must have only an identity in data storage 302.
A) project is quoted
It is the data structure that comprises location and identification item purpose information that project is quoted.In this data model, the abstract type of definition ItemReference (project is quoted) by name therefrom derives all items reference type.The ItemReference type definition virtual method of Resolve by name (parsing).The Resolve method is resolved ItemReference and is returned a project.The method is covered by the concrete subtype of ItemReference, and the latter realizes the function of given one search terms when quoting.Call the part of Resolve method as storage platform API 322.
(1)ItemIDReference
ItemIDReference (item id is quoted) is the subtype of ItemReference.It has defined Locator (steady arm) and ItemID field.Locator field name (i.e. sign) item domains.It is handled by the locator resolution method that the value of Locator can be resolved to item domains.The ItemID field is the ItemID type.
(2)ItemPathReference
ItemPathReference (item Path is quoted) is the particularization of the ItemReference of definition Locator and Path (path) field.Locator field identification item domains.It is handled by the locator resolution method that the value of Locator can be resolved to item domains.It is (relatively) path in the storage platform name space of root that the Path field comprises with the item domains that is provided by Locator.
Can not in set operation, use this class reference.Quote generally and must resolve by path resolving.The Resolve method of storage platform API 322 provides this function.
B) reference type hierarchy
Reform discussed above is represented by the reference type hierarchy shown in Figure 11.Other reference type of inheriting from these types can define pattern.They can be used as the type of aiming field in the relation statement.
3. project folder and classification
As below will more discussing fully, project team can be organized into the special item that is called project folder (not obscuring with the file of file).Yet do not resemble most of file system, a project can belong to a plurality of project folders, make when project in a project folder during accessed and revision, the project of this revision can directly be visited from another project folder subsequently.In fact, though can take place from different project folders the visit of a project, in fact real visit is same project.Yet project folder needn't have its all member's projects, or owns project together in conjunction with other file simply, makes the unnecessary deletion that causes project of deletion of a project folder.Yet in some embodiment of the present invention, a project must belong to a project folder at least, if make that unique project folder of specific project is deleted, then to some embodiment, this project is by deleted automatically, or in other embodiment, this project automatically becomes the member of default item file, and (for example, " TrashCan (dustbin) " item file is clipped in the conceptive similar name file that uses that is similar in various systems based on file and file.)
More discuss fully as following, project also can belong to the classification based on the feature of common description, feature as:
(a) item types (or type), (b) specific directly or the attribute of inheriting (or attribute), or (c) corresponding to the particular value (or value) of item attribute.For example, comprise that the project of the particular community of individual associated person information can belong to Contact (contact person) classification automatically, any project with associated person information attribute also belongs to this classification automatically.Equally, any project that has the position attribution of " New York City (New York) " value can belong to NewYorkCity (New York) classification automatically.
Classification is in the conceptive project folder part that is different from, project folder can comprise irrelevant mutually project (feature of promptly not having common description), and each project in classification has common type, attribute or the value (" common point ") that this classification is described, just this concomitant basis that forms the relation between other project in it and this classification or those projects.In addition, though the membership qualification of the project in particular file folder is not compulsory based on any particular aspects of this project, yet to some embodiment, all items with common point relevant with a classification in classification can automatically become such other member on the hardware/software interface system level.Conceptive, classification also can be regarded the phantom item file as, and its membership qualification is based on the ad hoc inquiry result of (as in the context of database), and the project that satisfies the condition (common point by classification is determined) of this inquiry should constitute such other membership qualification.
Fig. 4 is illustrated in the structural relation between project, project folder and classification in the various embodiments of the present invention.A plurality of projects 402,404,406,408,410,412,414,416,418 and 420 are members of each project folder 422,424,426,428 and 430.Some project belongs to an above project folder, belongs to project folder 422 and 424 as project 402.Some project, as project 402,404,406,408,410 and 412 also is the member of one or more classifications 432,434 and 436, and other project, as project 44,416,418 and 420 can not belong to any classification (though this major part does not resemble in certain embodiments, wherein has any attribute and hints membership qualification in the classification automatically, therefore in embodiment like that in order not to be the member of any classification, project should fully not have feature).Opposite with the hierarchy of file, classification and project folder all have more the structure as directed digraph.Under any circumstance, project, project folder and classification all are project (although being different item typess).
Opposite with file, file and catalogue, the feature of project of the present invention, project folder and classification is not " physics " in itself, because they do not have notional equivalence of physical container, thereby project can be present in position such more than.The ability that project is present in an above item file position and is organized into classification provides data processing and the storage organization ability that strengthens and enrich degree on the hardware/software interface level, has surmounted current in the art available ability.
4. pattern
A) basic schema
Create and the general basic of the project of use in order to provide, each embodiment of storage platform of the present invention comprises the basic schema of setting up the conceptual frame that is used to create and organize project and attribute.Basic schema has defined the project and the attribute of some particular type, and the feature that therefrom further derives these specific fundamental types of subtype.Use this basic schema that the programmer can be distinguished project (and type separately) and attribute (and type separately) conceptive.In addition, basic schema is listed the basic attribute set that all items can have, and (and corresponding item types) is that this elementary item (and corresponding item types) from basic schema is derived because all items.
As shown in Figure 7, for some embodiment of the present invention, basic schema definition three top layer type: Item (project), Extension (expansion) and PropertyBase (attribute base).As shown in the figure, the attribute definition by this basic " Item " item types item types.On the contrary, top layer attribute type " PropertyBase " does not have predefined attribute, only is an anchor point, therefrom derives all other attribute types, and the attribute type of all derivation interknits (deriving from single attribute type jointly) by it.The Extension type attribute defines this expansion and has expanded which project, and definition is with an expansion and another other sign of project phase region, because a project can have a plurality of expansions.
ItemFolder (project folder) is the subtype of Item item types, except the attribute of inheriting from Item, its characterizes the relation of the link be used to be established to its member (if any), although Identitykey (identity key) and Property (attribute) all are the subtype of PropertyBase.CategoryRef (catalogue is quoted) and then be the subtype of IdentityKey.
B) core schema
The various embodiment of storage platform of the present invention also are included as the core schema that top layer item types structure provides conceptual framework.Fig. 8 A is the block diagram that the project in the core schema is shown, and Fig. 8 B is the block diagram that attribute type in the core schema is shown.Be the function that is similar to core schema with the file of different extension name (* .com, * .exe, * .bat, * .sys etc.) and the differentiation of in based on file and file system folder, making between other criterion.In project-based hardware/software interface system, core schema has defined one group of core project type, their directly (by item types) or indirectly (by project subtype) all items feature is changed into that project-based hardware/software interface system is understood and can be with one or more core schema item typess predetermined or the direct processing of predictable mode.Predefined project type has reflected project the most frequently used in project-based hardware/software interface system, and therefore obtains the validity rank by understanding these project-based hardware/software interface system that constitute the predefine project type of core schema.
In certain embodiments, core schema can not be expanded, and, does not have the directly item types subclassification from basic schema of other type that is, unless as the item types of the specific predetermined derivation of the part of core schema.By forbidding the expansion (that is, by forbidding adding new project to core schema) to core schema, the use of storage platform trustship core schema item types is because each follow-up item types must be the subtype of core schema item types.This structure allows to have the dirigibility of resonable degree when the other item types of definition when maintenance has the benefit of one group of predetermined core project type.
With reference to figure 8A,, can comprise following one or more by the specific project type of core schema support to various embodiment of the present invention:
Category (classification): the repertory of this project type (and the subtype that therefrom derives) is shown in the effective classification in the project-based hardware/software interface system.
Commodity (article): as the project of the identified things of value.
Device (equipment): project with logical organization of support information processing power.
Document (document): have and to explain and opposite project by project-based hardware/software interface system by the content of explaining corresponding to the application program of Doctype.
Event (incident): the project of incident takes place in some in the record environment.
Location (position): the project in represents physical position (as the geographic position).
Message (message): the project of communication between two or more main bodys (below definition).
Principal (main body): have at least one sure susceptible of proof identity except that ItemId project of (as, the sign of individual, tissue, group, family, author, service etc.).
Statement (statement): have project, include but not limited to: strategy, reservation, voucher etc. about the customizing messages of environment.
Similarly with reference to figure 8B, can comprise following one or more by the particular community type of core schema support:
Certificate (certificate) (the basic PropertyBase type from basic schema derives)
PrincipalIdentityKey (subject identity key) (the IdentityKey type from basic schema derives)
PostalAddress (postal address) (the Property type derives from basic schema)
RichText (rich text) (the Property type derives from basic schema)
EAddress (Email geology) (the Property type derives from basic schema)
IdentitySecnrityPackage (identity rescue bag) (the Relationship type derives from basic schema)
RoleOccupancy (resident role) (the Relationship type derives from basic schema)
BasicPresence (basis exists) (the Relationship type derives from basic schema)
These projects and attribute further describe by the attribute of listing in Fig. 8 A and Fig. 8 B separately.
5. concern
Relation is a binary relation, and one of them project is designated as the source, and another is designated as target.Source item and destination item interrelate by relation.The life cycle of the general control relation of source item.That is, deleted when source item, the relation between the project is also deleted.
Relation is classified into: comprise (Containment) and quote (Reference) relation.The life cycle of relation of inclusion controlled target project, and adduction relationship does not provide any life cycle management semanteme.Figure 12 illustrates the mode of relation classification.
The relation of inclusion type is classified into again to be held (Holding) and embeds (Embedding) relation.When relation that all of a project are held is removed, this project is deleted.Hold and concern the life cycle of counter mechanism controlled target by reference.The relation of embedding can be to compound project modeling, and can be counted as the exclusive relation of holding.A project can be one or more targets of holding relation; But a project can only be a target that embeds relation.As the project of the target of the relation of embedding can not be that arbitrary other held or embedded the target that concerns.
Adduction relationship is the life cycle of controlled target project not.They can be that suspension-destination item can not exist.Any place (that is, comprising remote data storage) modeling that adduction relationship can be used at overall project name space is quoted project.
The acquisition project does not obtain its relation automatically, and application program is the relation of request items clearly.In addition, revise relation and do not revise source or destination item; Similarly, add relation and do not influence source/destination item.
A) relation statement
The following element definition of explicit relationship type;
Specified relationship name in Name (name) attribute
One of following relationship type: hold, embed, quote.This appointment in Type (type) attribute.
The source and target end points.Each end points is specified institute's referenced items destination name and type.
The source endpoint field generally is ItemID type (without proper notice), and must quote the project in the data storage identical with relationship example.
To holding and the relation of embedding, the target endpoint field must be the ItemIDReference type, and it must quote the project in the storage identical with relationship example.To adduction relationship, target endpoint can be any ItemReference type, and can quote the project in other storage platform data storage.
Can be able to randomly state one or more fields of scalar or PropertyBase type.These fields can comprise the data that are associated with this relation.
Relationship example is stored in the holotopy table.
Each relationship example is uniquely by combination (source ItemID, relations I D) sign.All are derived from the relation of given project, and relations I D is unique in given source ItemID, and no matter their type.
Source item is the owner of relation.And the life cycle that the project control that is designated as the owner concerns, relation itself is separated with the project relevant with them.Storage platform API 322 is provided for representing the mechanism of the relation that is associated with project.
Here be the example of a relation statement.
<Relationship?Name=″Employment″BaseType=″Reference″>
<Source?Name=″Employee″ItemType=″Contact.Person″/>
<Target?Name=″Employer″ItemType=″Contact.Organization″
ReferenceType=″ItemIDReference″/>
<Property?Name=″StartDate″Type=″the?storage
platformTypes.DateTime″/>
<Property?Name=″EndDate″Type=″the?storage
platformTypes.DateTime″/>
<Property?Name=″Office″Type=″the?storage
platformTypes.DateTime″/>
</Relationship>
This is the example of adduction relationship.If quoting the individual event of being quoted by the source does not exist, then can not create this relation.And if this individual event is deleted, the relationship example between individuals and organizations is also deleted.Yet if organize project deleted, concern not deletedly, and it hangs.
B) hold relation
The life cycle management that the relation held is used for the based target project comes the reference count modeling.
Project can be the source endpoint of zero or a plurality of relations of project.The project that is not the embedding project can be the target of holding in the relation one or more.
The target endpoint reference type must be ItemIDReference, and it must quote the project in the storage identical with relationship example.
The relation of holding is implemented the life cycle management of target endpoint.Hold relationship example and be atomic operation as the establishment of the project of target.Can create the hold relationship example of other of same project as target.Hold relationship example when deleted when having given project last as target endpoint, this destination item is also deleted.
The type of the end points project of appointment is generally forced when the example of this relation of establishment in the relation statement.The type of end points project can not change after relation is set up.
Hold to close in the name space that ties up to the formation project and play key effect.They comprise " Name " attribute, and its objective definition project is with respect to the source item destination name.To all relations of holding that is derived from given project, relative name is unique.Begin to form full name of this project from root Element to the ordered list of the relative name of given project.
The relation of holding forms a directed acyclic graph (DAG).Hold when concerning in establishment, system guarantees not produce the loop, thereby the name space of guaranteeing project forms DAG.
Though hold the life cycle that concerns the controlled target project, it is the consistance of the operation of controlled target end points project not.Destination item is independent of in operation by holding the project that relation has it.As on the project in source of holding relation duplicate, move, back up and other operation does not influence project as homonymous target-for example, backup file folder project automatically do not back up this document press from both sides in all items (FolderMember (file member) concern in target).
Be the example of holding relation below:
<Relationship?Name=″FolderMembers″BaseType=″Holding”>
<Source?Name=″Folder″ItemType=″Base.Folder″/>
<Target?Name=″Item″ItemType=″Base.Item″
ReferenceType=″ItemIDReference″/>
</Relationship>
The FolderMember relation makes the notion of file become the generic set of project.
C) embed relation
Embed the conceptual modelling of relation with the exclusive control of the life cycle of destination item.They allow the notion of complex item.
Embed relationship example and be atomic operation as the establishment of the project of target.Project can be the source of zero or a plurality of embedding relation.Yet a project can be one and only be a target that embeds relation.As the project that embeds the target that concerns can not be to hold the target of relation.
The target endpoint reference type must be ItemIDReference, and it must quote the project in storing with the relationship example identical data.
The type of the end points project of appointment is generally forced when the example of this relation of establishment in the relation statement.The type of end points project can not change after relation is set up.
Embed the operational consistency of this target endpoint of relation control.The operation of for example, serialization project can comprise serialization, and all are derived from all embedding relations of this project and all its targets; The project of duplicating is also duplicated all its embedding projects.
Be the example statement below:
<Relationship?Name=″ArchiveMembers″BaseType=″Embedding”>
<Source?Name=″Archive″ItemType=″Zip.Archive″/>
<Target?Name=″Member″ItemType=″Base.Item″
ReferenceType=″ItemIDReference″/>
<Property?Name=″ZipSize″Type=″the?storage
platformTypes.bigint″/>
<Property?Name=″SizeReduction″Type=″the?storage
platformTypes.float″/>
</Relationship>
D) adduction relationship
Adduction relationship is not controlled the life cycle of the project that it quotes.Especially, adduction relationship does not guarantee the existence of target, and the type that does not also guarantee target is as appointment in the relation statement.This means that adduction relationship can hang.And adduction relationship can be quoted the project in other data storage.Adduction relationship can be regarded the notion that is similar to the link on the webpage as.
Be the example of adduction relationship statement below:
<Relationship?Name=″DocumentAuthor″BaseType=″Reference″>
<Sourc?ItemType=″Document″
ItemType=″Base.Document″/>
<Target?ItemType=″Author″ItemType=″Base.Author″
ReferenceType=″ItemIDReference″/>
<Property?Type=″Role″Type=″Core.CategoryRef″/>
<Property?Type=″DisplayName″Type=″the?storage
platformTypes.nvarchar(256)″/>
</Relationship>
End points in target allows any reference type.The project that participates in adduction relationship can be any item types.
Adduction relationship is used for the most of non-life cycle management relationship modeling between the project.Because do not force the existence of target, adduction relationship is convenient to loosely-coupled relationship modeling.Adduction relationship can be used for being included in the destination item in the storage on other computing machine in other storage.
E) rule and constraint
Following ancillary rules and constraint are applied to relation:
1. project must be the target of (only embeds relation) or (one or more relation of holding).An exception is a root Element.Project can be the target of zero or a plurality of adduction relationships.
2. concern that as embedding the project of target can not be to hold the source of relation.It can be the source of adduction relationship.
3., then can not be the source of holding relation if project is from document upgrading.It can be the source of relation of embedding and adduction relationship.
4. the project from document upgrading can not be the target of the relation of embedding.
F) Guan Xi ordering
In at least one embodiment, the ordering of storage platform support relation of the present invention.Attribute by " Order (ordering) " by name in the fundamental relation definition is finished ordering.In the Order field, there is not unique constraints.Do not guarantee to have the order of the relation of same " Order " property value, yet guarantee that they can sort after the relation of band lower " Order " value and before the relation with higher " Order " field value.
Application program is by (SourceItem ID, RelationshipID Order) go up the relation that ordering obtains giving tacit consent to order in combination.All relationship example that are derived from given project are ranked into single set, and no matter the type that in set, concerns.Yet this guarantee given type (as, all relations FolderMembers) are ordering subclass of the set of relationship of given project.
The data storage API 312 that is used to the relation of handling realizes the operation of the ordering of one group of support relation.Introduce following term and help to explain those operations:
RelFirst is first relation of band order value OrdFirst in the ordered set;
RelLast is last relation of band order value OrdLast in the ordered set;
RelX is the given relation of band order value OrdX in the set;
RelPrev approaches the relation of the band of RelX less than the order value OrdPrev of OrdX most in the set; And
RelNext approaches the relation of the band of RelX greater than the order value OrdNext of OrdX most in the set.
InsertBeforeFirst(SourceItemID,Relationship)
The relation of inserting is as first relation in the set.The value of " Order " attribute of new relation can be less than OrdFirst.
InsertAfterLast(SourceItemID,Relationship)
The relation of inserting is as last relation in the set.The value of " Order " attribute of new relation can be greater than OrdLast.
InsertAt(SourceItemID,ord,Relationship)
Insertion has the relation to the value of " Order " attribute appointment.
InsertBefore(SourceItemID,ord,Relationship)
Before having the relation of given order value, insert this relation.New relation can be assigned with " Order " value, and it but does not comprise this two values between OrdPrev and ord.
InsertAfter(SourceItemID,ord,Relationship)
After having the relation of given order value, insert this relation.New relation can be assigned with " Order " value, and it but does not comprise this two values between ord and OrdNext.
MoveBefore(SourceItemID,ord,Relationship)
Move to band and specify before the relation of " Order " value bringing the relation of deciding relations I D.Relation can be assigned with new " Order " value, and it but does not comprise this two values between OrdPrev and ord.
MoveAfter(SourceItemID,ord,Relationship)
Move to band and specify after the relation of " Order " value bringing the relation of deciding relations I D.This relation can be assigned with new order value, and it but does not comprise this two values between ord and OrdNext.
Arrive as prerequisite, each project must be the member of project folder.According to relation, each project must have relation with a project folder.In some embodiment of the present invention, some relation is represented by the relation that exists between all projects.
As realization to various embodiments of the present invention, the relation provide to binary relation, it extends to another project (target) by a project (source).Relation is had by source item (extending its project), and therefore relation is removed if the source is removed then (deleted as relation when source item is deleted).In addition in some cases, relation can be shared the ownership of (owning together) destination item, and such ownership only can be reflected in IsOwned (by the having) attribute (or its equivalent attribute) of relation (as Fig. 7 to shown in the attribute of a relation type).In these embodiments, create new IsOwned relation and increase progressively reference count on this destination item automatically, and delete can successively decrease the reference count on this destination item of such relation.To these specific embodiments, if project has the reference count greater than 0, then exist, if item count reaches 0 deletion automatically.Again, project folder is the project with one group of relation of (maybe can have) and other project, and these other projects comprise the membership qualification of project folder.Other actual realization of relation is possible, and is conceived by the present invention and to realize function described herein.
No matter actual realization how, relation is the selectable connection from an object to another object.A project belongs to an above project folder and one or more classification, no matter and these projects, file and classification that to be publicly-owned or privately owned ability be is determined by the meaning that gives existing in the project-based structure (or shortage).These logical relations are to distribute to the meaning of one group of relation, no matter and the physics realization that it is used for realizing function described here specially how.Logical relation is set up (or opposite) between project and file or classification, because each of project folder and classification all is the project of particular type in essence.Therefore, can be as other project project folder and classification are worked (duplicate, add in the email message, embed document or the like, and unrestricted), and project folder can use identical machine-processed serialization and anti-serialization (import and derive) as other project with classification.(for example in XML, all items can have serialized form, and these lattice are applied to project folder, classification and project comparably).
The above-mentioned relation of the relation between expression project and the project folder thereof logically can extend to project folder, extend to project or both from project folder from project.The relation that extends to project folder from project shows that this project folder is publicly-owned for this project in logic, and shares its membership qualification information with this project; On the contrary, the logical relation that lacks from the project to the project folder shows that this project folder is privately owned to this project, and does not share its membership qualification information with this project.Similarly, the relation that extends to project from project folder shows that this project is publicly-owned in logic, and can share with this project folder, shows that this project is privately owned and can not shares and lack the logical relation that extends to project from project folder.Therefore, when when other system derives project folder, it is the project of " publicly-owned ", it is shared in new environment, and when its project folder of project search is sought other sharable project, it is the project folder of " publicly-owned ", and it provides information about shared with the project that belongs to it to this project.
Fig. 9 is the block diagram that interconnected relationship between project folder (itself also is a project), its member's project and project folder and the member's project thereof is shown.Project folder 900 has a plurality of projects 902,904 and 906 as its member.Project folder 900 have from the itself to the project 902 concern 912, it shows that project 902 is publicly-owned, and can with project folder 900, its member 904 and 906 and any other project folder, classification or the project (not shown) of any accessible items file 900 share.Yet it doesn't matter from project 902 to project folder project 900, and this shows that 900 pairs of projects 902 of project folder are privately owned, and do not share its membership qualification information with project 902.On the other hand, project 904 have really from the itself to the project folder 900 concern 924, this shows that project folder 900 is publicly-owned, and shares its membership qualification information with project 904.Yet 904 relation not from project folder 900 to project, this shows that project 904 is privately owned, and not with project folder 900, its other member 902,906, and any other project folder, classification or the project (not shown) of accessible items file 900 share.Opposite with its relation (or not having these relations) to project 902 and 904, project folder 900 have from itself to project 906 concern 916, and project 906 have get back to project folder 900 concern 926, show that together project 906 is publicly-owned, and can to project folder 900, its member 902 and 904 and any other project folder, classification or the project (not shown) of accessible items file 900 share, and project folder 900 is publicly-owned, and shares its membership qualification information with project 906.
As preceding discussion, the project in project folder does not need to share concomitant, because project folder is not by " description ".On the other hand, classification is by the common common point of all its member's projects is described.Therefore, the membership qualification of classification is limited to the project with described common point inherently, and in certain embodiments, all items that satisfies the description of classification automatically becomes such other member.Therefore, although project folder allows to represent unessential type structure by its membership qualification that classification allows membership qualification based on the common point of definition.
Certainly, it is logic in essence that classification is described, thereby classification can be described by any logical expressions of type, attribute and/or value.For example, can be its membership qualification to the logical expressions of classification, have one of two attributes or both projects to comprise.If these attributes that classification is described are " A " and " B ", then such other membership qualification can comprise have attribute A and do not have B project, have attribute B and the project that do not have the project of A and have attribute A and B concurrently.Describe the logical expressions of attribute by logical operator " OR (or) ", wherein describing member's group by classification is the project with attribute A OR B.As understood by those skilled in the art, also can use similar logical operator (including but not limited to independent " AND (with) " " XOR (XOR) " and " NOT (non-) " or its combination) to describe classification.
Although have any different between project folder (describing) and classification (describing), in many embodiment of the present invention, the classification relation that arrives project in principle reaches the above same quadrat method in the face of project folder and project of the project relationship that arrives classification and discloses.
Figure 10 is the block diagram that the interconnected relationship between classification (itself also being project), its member's project, classification and the member's project thereof is shown.Classification 1000 has a plurality of projects 1002,1004 and 1006 as the member, and all these shares certain combination of common attribute, value and the Class1 008 (concomitant description 1008 ') described by classification 1000.Classification 1000 has from itself to project 1002 relation, it shows that project 1002 is publicly-owned, and can with classification 1000, its member 1004 and 1006 and any other classification, project folder or the project (not shown) of addressable classification 1000 share.Yet, 1000 relation not from project 1002 to classification, this shows that 1000 pairs of projects 1002 of classification are privately owned, and does not share the membership qualification information with project 1002.On the other hand, project 1004 have really from itself to classification 1000 concern 1024, this shows that classification 1000 is publicly-owned, and shares its membership qualification information with project 1004.Yet, there is not the relation that extends to project 1004 from classification 1000, this shows that project 1004 is privately owned, and can not with classification 1000, its other member 1002 and 1006 and any other classification, project folder or the project (not shown) of addressable classification 1000 share.Opposite with the relation (or not having this relation) of it and project 1002 and 1004, classification 1000 have from itself to project 1006 concern 1016, and what project 1006 had classification of getting back to 1000 concerns 1026, this shows that together project 1006 is publicly-owned, and can with classification 1000, its program member 1002 and 1004 and any other classification, project folder or the project (not shown) of addressable classification 1000 share, and classification 1000 is publicly-owned, and shares its membership qualification information with project 1006.
At last, because classification and project folder itself are projects, and project can cross correlation, classification can be related to project folder, vice versa, and in some other embodiment, classification, project folder and project can be related to other classification, project folder and project respectively.Yet in various embodiments, item file clamping structure and/or classification structure forbid comprising the loop on the hardware/software interface system level.When project folder and classification similar during in digraph, forbid that the embodiment in loop is similar to directed acyclic graph (DAG), according to the mathematical definition in graph theory field, DAG does not wherein have the path to begin on same summit and the digraph that stops.
6. extensibility
As mentioned above, this storage platform aims to provide originate mode collection 340.Yet at least in certain embodiments, this storage platform allows also to comprise that the clients such as (ISV) of stand alone software retail trader creates new mode 3 44 (being new project and nested element type).This section is passed the mechanism that item types that expansion defines and nested element type (or being called for short " element " type) are conceived to create this pattern through discussion in originate mode collection 340.
Preferably, the following constraint of expansion of the initial set of project and nested element type:
Allow ISV to introduce new item types, i.e. subtype Base.Item;
Allow ISV to introduce new nested element type, i.e. subtype Base.NestedElement;
Allow ISV to introduce new expansion, i.e. subtype Base.NestedElement; But
ISV can not subtypeization by any kind of originate mode collection 340 definition of storage platform (project, embed element or expansion type).
The item types or the embedding element type that define owing to the originate mode group by storage platform may mate the needs of ISV application program fully, must allow ISV to customize the type.This has just considered the notion of expansion.Expansion is the example of strong typing, still (a) they can not independently exist, and (b) they must be attached to project or nested element.
Except solving the needs to the pattern extensibility, expansion also is intended to solve " polymorphic typeization " problem.In certain embodiments because storage platform may not supported many inheritances or overlapping subtype, application program can use expansion as the overlapping type instance of modelling (as document be legal documents be again security document) method.
A) project expansion
For the extensibility of project is provided, data model also defines the abstract type of Base.Extension by name.This is the root type of the hierarchy of expansion type.Application program can subtype Base.Extension, to create specific expansion type.
In basic schema as the Base.Extension type of giving a definition:
<Type?Name=″Base.Extension″IsAbstract=″True″>
<Propety?Name=″ItemID″
Type=″the?storage?platformTypes.uniqueidentified″
Nullable=″false″
MultiValued=″false″/>
<Property?Name=″ExtensionID″
Type=″the?storage?platformTypes.uniqueidentified″
Nullable=″false″
MultiValued=″false″/>
</Type>
The ItemID field comprises the ItemID of the project related with this expansion.Project with this ItemID must exist.If bringing the project of deciding ItemID does not exist, then can not create expansion.When project deleted, deleted with all expansions of same ItemID.(ItemID ExtensionID) has identified the expansion example to tuple uniquely.
The similar of expansion type is in the structure of item types:
Expansion type has field;
Field can be primitive or nested element type; And
Expansion type can be by subclassification.
Following restriction is applied to expansion type
Expansion can not be the source and target of relation;
The expansion type example can not be independent of project and exist; And
Expansion type can not be as the field type in the storage platform type definition
Not constraint of type to expansion that can be related with given item types.Any expansion type allows any item types of expansion.When a plurality of expansion examples are affixed to a project, they are independently of one another in structure and behavior.
The expansion example is stored respectively and from item access.All expansion type examples can be from overall extended view visit.Can form an effectively inquiry, it will return all examples of the expansion of given type, and no matter they are associated with the project of what type.The programming model that storage platform API provides and can store, retrieves and the modification project is expanded.
Expansion type can be to use the single succession model of storage platform to come the type of subtypeization.Derive the new expansion type of establishment from an expansion type.The structure of an expansion or behavior can not cover or the structure or the behavior of alternative project type hierarchical structure.
Be similar to item types, the expansion type example can directly be visited by the view that is associated with this expansion type.The ItemID of expansion shows which project they belong to, and can be used for from the corresponding item objects of global keys eye diagram retrieval.
Be the purpose of operational consistency, expansion is considered to be the part of project.Duplicate/move, other operation commonly used of backup/restoration and storage platform definition can operate in the expansion as the part of project.
Consider following example.In Windows type centralized definition Contact type.
<Type?Name=″Contact″BaseType=“Base.Item”>
<Property?Name=″Name″
Type=″String″
Nullable=″false″
MultiValued=″false″/>
<Property?Name=″Address″
Type=″Address″
Nullable=″true″
MultiValued=″false″/>
</Type>
The CRM application developer is liked the CRM application extensions is appended to the contact person who is stored in the storage platform.The application developer definition comprises the CRM expansion of the treatable additional data structure of application program.
<Type?Name=″CRMExtension″BaseType=″Base.Extension″>
<Property?Name=″CustomerID″
Type=″String″
Nullable=″false″
MultiValued=″false″/>
...
</Type>
The HR application developer wishes also additional data to be appended to the contact person.These data are independent of the CRM application data.Application developer also can be created expansion
<Type?Name=″HRExtension″EBaseType=″Base.Extension″>
<Property?Name=″EmployeeID″
Type=″String″
Nullable=″false″
MultiValued=″false″/>
...
</Type>
CRMExtension and HRExtension can append to two independent expansions of contacts purpose.They can be created and visit independently of one another.
In above-mentioned example, the field of CRMExtension type and method can not cover the field and the method for contact person's hierarchy.The example that it should be noted that the CRMExtension type can be affixed to the item types that is different from the contact person.
When the searching linkman project, automatically do not retrieve its project expansion.Given contact item can visit its relevant project expansion with searching with the expansion of same ItemID by inquiring about overall extended view.
Can visit CRMExtension expansions all in the system by CRMExtension type view, no matter and what project they belong to.Same project ID is shared in all items expansion of a project.In above-mentioned example, Contact project example and additional CRMExtension and HRExtension example are shared same ItemID.
Following table has been summed up similarity and the difference between Item (project), Extension (expansion) and NestedElement (nested element) type:
Item, ItemExtension and NestedElement
Figure C0382694100441
Figure C0382694100451
B) expansion NestedElement type
The nested element type need not the mechanism identical with item types be expanded.The expansion of nested element uses the mechanism identical with the nested element type field to store and visit.
Data model has defined the root of the nested element type of Element by name (element):
<Type?Name=″Element″
IsAbstract=″True″>
<Property?Name=″ElementID″
Type=″the?storage?platformTypes.uniqueidentifier″
Nullable=″false″
MultiValued=″false″/>
</Type>
The NestedElement type is inherited from this type.The NestedElement element type is definition one field in addition, and it is many element of sets element.
<Type?Name=″NestedElement″BaseType=″Base.Element″
IsAbstract=″True″>
<Property?Name=″Extensions″
Type=″Base.Element″
Nullable=″false″
MultiValued=″true″/>
</Type>
The NestedElement expansion is different from the project expansion in the following areas:
The nested element expansion is not an expansion type.They do not belong to the Base.Extension type is the expansion type hierarchy of root.
Nested element expansion is stored with other field of this project, and be not the overall situation addressable-can not form the inquiry of all examples of retrieving given expansion type.
As store and store these expansions other nested element (or project).As other nest set, the NestedElement expansion is existed among the UDT.They can visit by Extension (expansion) field of nested element type.
The set interface that is used to visit multi-valued attribute also is used for visit and the iteration on the type superset.
Below table sum up and compared the Item expansion and NestedElement expands.
Item expansion and NestedElement expansion
D. database engine
As above mention, data storage realizes on database engine.In the present embodiment, database engine comprises such as realization SQL query language such as Microsoft SQL Server engines, has the relevant database engine that object relationship is expanded.This section has been described the mapping of the data model of data storage realization to the relation storage according to present embodiment, and the information of being used by the client computer of storage platform is provided on logic API.Yet be appreciated that when adopting different database engines and can adopt different mappings.Really, except realization storage platform conceptual data model on the relevant database engine, also can on other types of database, realize, as object-oriented and XML database.
Object-oriented (OO) Database Systems are that programming language object (as C++, Java) provides continuation and affairs.The storage platform notion of " project " can be mapped to the object in the object-oriented system well, though the set that embeds must be added to object.Other storage platform type concepts such as similar inheritance and nested element type also are mapped to the system of object-oriented type.The object-oriented system is support target identity usually; Therefore, the project identity can be mapped to object identity.The behavior of project (operation) is mapped to object method well.Yet the common inorganizable ability of object-oriented systems is also very poor aspect search.And object-oriented systems does not provide the support to destructuring and semi-structured data.For supporting complete storage platform data model described herein, need add object data model to as notions such as relation, file and expansions.In addition, need to realize as upgrading, synchronously, mechanism such as notice and security.
Be similar to object-oriented systems, support the system of inheriting type based on single based on the XML database of XSD (XML mode-definition).Entry type system of the present invention can be mapped to XSD type model.XSD does not provide the support to behavior yet.The behavior of the necessary addition item of the XSD of project.The single XSD document of XML database processing is also inorganizable and widen search capability.As object-oriented database,, need be incorporated into this XML database as other notions such as relation and files for supporting data model described herein; And need to realize as synchronously, mechanism such as notice and security.
1. use the data storage of UDT to realize
In the present embodiment, the relevant database engine 3 14 that comprises Microsoft SQL Server engine is in one embodiment supported built-in scalar type.Built-in scalar type is " original " and " simply ".They are that original meaning is, the user can not define themselves type; They are that simple meaning is, the user can not encapsulate complicated structure.User-defined type (UDT hereinafter referred to as) can be come the expansion type system by defining complicated structured type by making the user, and a kind of mechanism that is used for surpassing or surmount the type extensibility of original scalar type system is provided.In case defined by the user, the type system that UDT can be used for using built-in scalar type Anywhere.
Press one aspect of the present invention, the storage platform pattern is mapped to the UDT class in the database engine storage.The data storage project is mapped to the UDT class that derives from the Base.Item type.Be similar to project, expansion also can be mapped to the UDT class and use and inherit.The root expansion type is Base.Extension, derives all expansion types from it.
UDT is the CLR class, and it has state (being data field) and behavior (being routine).Use any managed language (c#, VB.NET etc.) definition UDT.UDT method and operational character can be called by the example at the type in T-SQL.UDT can be: in the row in the type, T-SQL of row the type of the parameter of routine or in T-SQL type of variables.
Following example shows the basis of UDT.Suppose that MapLib.dll has the procedure set that is called MapLib.In this procedure set, under name space BaseTypes, there is the class that is called Point:
namespace?BaseTypes
{
public?class?Point
{
// return distance from specified point.
public?double?Distance(Point?p)
{
// reentry point p and the distance between this
}
// other content in such
}
}
Following T-SQL code is tied to class Point the SQL Server UDT that is called Point.The first step is called " Create Assembly " (creation procedure collection), and it is loaded into database with the MapLib procedure set.Second step " Create Type " (establishment type) with establishment user defined type " Point ", and binds it to managed type B astTypes.Point:
CREATE?ASSEMBLY?Maplib
FROM′\\myserv\share\MapLib.dll′
go
CREATE?TYPE?Point
EXTERNAL?NAME′BaseTypes.Point′
go
In case be created, " Point " UDT can use the row in the tabulation, and this method can be called in T-SQL as followsly:
Create?table?Cities(
Name?varchar(20),
State?varchar(20),
Location?Point)
--the retrieval city is to the distance of coordinate (32,23)
Declare@p?point(32,23),@distance?float
Select?Location::Distance(@p)
From?Cities
The storage platform pattern is direct to being mapped in of UDT class on high-level fully.Generally speaking, the storage platform pattern is mapped to the CLR name space.The storage platform type is mapped to the CLR class.The succession mirror image of CLR class the succession of storage platform type, and the storage platform attribute is mapped to the CLR generic attribute.
Hierarchy of items shown in Figure 29 is used as an example in this document.It shows from wherein deriving the Base.Item type of all items type, and one group of item types (for example, Contact.Person and Contact.Employee) of deriving, and wherein inherits by arrow and indicates.
2. project mapping
Can be searched for globally in order to wish project, and in the relational data of present embodiment, support to inherit and the type substitutability, a kind of possible realization that the project in database storing is stored is to store all items in the single table of the row that have type B ase.Item.The type of service substitutability can be stored all types of projects, and can come filtered search by the item types and the subtype of the operational character of " is of (type) " of using Yukon.
Yet, owing to involve the overhead that is associated with this method in the present embodiment, divide projects by top type, make the project of each type " family " store in the independent table.In this partition mode, each is directly created a table from the item types that Base.Item inherits.As mentioned above, the substitutability of these type type of service is stored in the suitable type family table below the succession.Only inherit and ad hoc handled from the first order of Base.Item.For exemplary projects hierarchy shown in Figure 29, this can obtain following type family table:
create?tabele?Contact.[Table!Person](
_Item?Contact.Person?not?null
{Change?tracking?information}
)
create?table?Doc.[Table!Document](
_Item?Doc.Document?not?null,
{Change?tracking?information}
)
Use " shade " but the copy of the overall situation search attribute of table storage all items.This table can be safeguarded by the Update () method of storage platform API, make the change of all data by the method.Do not resemble type family table, this overall repertory only comprises the top scalar attribute of this project, rather than full UDT item objects.The structure of overall situation repertory is as follows:
create?table?Base.[Table!Item](
ItemID?uniqueidentifier?not?null constraint[PK_Clu_Item!ItemID]primary?key?clustered,
TypeID?uniqueidentifier?nul?null,
{Additional?Properties?of?Base.Item},
{Change?tracking?information}
)
Overall situation repertory allows to navigate to the item objects that is stored in the type family table by representing ItemID and TypeID (type i D).Project in the common storage of identification data uniquely of ItemID.Can use the metadata of not giving description here that TypeID is mapped to type name and the view that comprises this project.
Because seeking project by its ItemID all is operation commonly used under the context of overall repertory and other situation, the therefore given ItemId of project provides GetItem () function to come the search terms object.This function has following statement:
Base.Item?Base.Getltem(uniqueidentifier?ItemID)
For ease of visit and the hiding as much as possible details that realizes, all inquiries of project can be carried out the view that makes up on the table that impinges upon above-mentioned project.Particularly, each item types is created view at family's table of adequate types.These type views can be selected the type that is associated, comprise all items of subtype.For simplicity, except the UDT object, view can represent row to all TLDs that comprise the type of inheriting field.View to exemplary projects hierarchy shown in Figure 29 is as follows:
create?view?Contact.Person?as
Select_Item.ItemID, { attribute of Base.Item }, { attribute of Contact.Person }, { change trace information }, _ Item
from?Contact.[Table!Person]
--notice that the Contact.Employee view uses " where " to judge
--limit the Item Sets that is found to the example of Contact.Employee
create?view?Contact.Employee?as
Select_Item.ItemID, { attribute of Base.Item }, { attribute of Contact.Person }, { attribute of Contact.Employee },
{ change trace information }, cast (_ item as Contact.Employee)
from?Contact.[Table!Person]
where_Item?is?of(Contact.Employee)
create?view?Doc.Document?as
Select_Item.ItemID, { attribute of Base.Item }, { attribute of Doc.Document }, { change trace information }, _ Item
from?Doc[Table!Document]
--notice that the Doc.WordDocument view uses " where " to judge
--limit the Item Sets that is found to the example of Doc.WordDocument
create?view?Doc.WordDocument?as
Select_Item.ItemID, { attribute of Base.Item }, { attribute of Doc.Document }, { attribute of Doc.WordDocument },
{ change trace information }, cast (_ Item as Doc.WordDocument)
from?Doc.[Table!Document]
where_Item?is?of(Doc.WordDocument)
For the purpose of integrality, view also can be created on overall repertory.This view can be showed and epiphase row together at first:
create?view?Base.Item?as
Select ItemID, TypeID, { attribute of Base.Item }, { change trace information }
from?Base.[Table!Item]
3. expansion mapping
Expansion is very similar to project, and has some identical requirement.As support adoptive another root type, many same considerations and relatively compromise during expansion is stored.For this reason, to the mapping of the similar type of expanded application family, rather than single table method.Certainly, in other embodiments, can use single table method.
In the present embodiment, expansion by ItemID only with an item association, and be included in ExtensionID unique in the context of project.Expansion table has to give a definition:
create?table?Base.[Table!Extension](
ItemID?uniqueidentifier?not?null,
ExtensionID?uniqueidentifier?not?null,
TypeID?uniqueidentifier?not?null,
{ attribute of Base.Extension },
{ change trace information },
constraiint[PK_Clu_Extension!ItemID!ExtensionED]
primary?key?clustered(ItemID?asc,ExtensionID?asc)
)
As project, given ItemID and the right identity of ExtensionID of comprising can provide a function to be used for the retrieval expansion.This function has following statement:
Base.Extension?Base.GetExtension(uniqueidentifier?ItemID,uniqueidentifier?ExtensionID)
Be similar to the item types view, can create view each expansion type.Suppose that the expansion hierarchy is parallel with the exemplary projects hierarchy, have following type: Base.Extension, Contact.PersonExtension, Contact.EmployeeExtension.Can create following view:
create?view?Base.Extension?as
Select ItemID, ExtensionID, TypeID, { attribute of Base.Extension }, { change trace information }
from?Base.[Table!Extension]
create?view?Contact.[Extension!PersonExtension]as
Select_Extension.ItemID, _ Extension.ExtensionID, { attribute of Base.Extension },
{ attribute of Contact.PersonExtension },
{ change trace information }, _ Extension
from?Base.[Table!PersonExtension]
create?view?Contact.[Extension!EmployeeExtension]as
Select_Extension.ItemID, _ Extension.ExtensionID, { attribute of Base.Extension },
{ attribute of Contact.PersonExtension },
{ attribute of Contact.EmployeeExtension }, { change trace information },
cast(_Extension?as?Contact.EmployeeExtension)
from?Base.[Table!PersonExtension]
where_Extension?is?of(Contact.EmployeeExtension)
4. nested element mapping
Nested element is can be embedded into project, expansion, relation or other nested element to form the type of dark nested structure.Be similar to project and expansion, nested element realizes as UDT, but they are stored in project and the expansion.Therefore, nested element does not surmount their project and the Storage Mapping of extension container.In other words, in system, do not have directly to store the table of the example of NestedElement type, and be not specifically designed to the view of nested element.
5. object identity
Each entity in data model, promptly each project, expansion and relation have unique key assignments.A project is identified uniquely by its ItemId.(ItemId ExtensionId) identifies uniquely by compound key in expansion.Relation is by compound key (ItemId, RelationId) sign.ItemId, ExtensionId and RelationshipId all are GUID values.
6.SQL object naming
All objects of creating in data storage can be stored in from the SQL pattern name that storage platform pattern name derives.For example, storage platform basic schema (normal claim " Base ") can be created in the type in " [System.Storage] " SQL pattern, as " [System.Storage] .Item ".The name that generates can be with the determiner prefixing to eliminate the conflict of name.Can use at suitable place exclamation mark (! ) as the separator of each logical gate of name.Following table has been summarized the naming convention that is used for object in data storage.Each schema elements (project, expansion, relation and view) is listed in naming convention with the modification of the example that is used for visit data storage.
Object The name character modification Describe Example
Master project search view Master!Item The summary of project is provided in current item domains ?[System.Storage].?[Master!Item]
Typed project search view Item types All properties data from project and any parent type are provided ?[AcmeCorp.Doc].?[OfficeDoc]
Main expanded search view Master!Extension Be provided at the summary of all expansions in the current item domains ?[System.Storage].?[Master!Extension]
Typed expanded search view Expansion type Provide all properties data to expansion ?[AcmeCorp.Doc].?[Extension!SlickyNote]
The primary relation view Master!Relationship Be provided at all relations in the current item domains [System.Storage]. [Master!Relationship]
Summary
Relational view The relation name The data that provide all to be associated with given relation [AcmeCorp.Doc].[Relationship!AuthorsFromDocument]
View The view name Definition provides row/type based on mode view [AcmeCorp.Doc].[View!DocumentTitles]
7. row name
When shining upon arbitrary object model to storage, naming conflict might take place in the additional information owing to storing with application object.For avoiding naming conflict, the particular column of all non-types (not mapping directly to the row of the attribute of the name in the type declarations) underscore character () prefixing.In the present embodiment, underscore character () does not allow the beginning character as any identifier attribute.In addition, for being unified in the name between CLR and the data storage, all properties of storage platform type or schema elements (relation etc.) should have first character of capitalization.
8. search view
Provide view by storage platform, be used to search for the content of storage.Provide SQL view to each project and expansion type.In addition, provide view to support relation and view (by the data model definition).All SQL views and the bottom table in storage platform are read-only.As will be more fully described below, use the Update () method of storage platform API can store or change data.
<view name 〉] visit. BookSales] visit.Because the output format of view on the basis of each view be self-defining (by that side of definition view provide query-defined arbitrarily), row define based on mode view and are directly shone upon.
All SQL search views in the storage platform data storage use the following ordering agreement of row:
1. as the view result's of ItemId, ElementId, RelationshipId etc. logic " key " row
2. as the metadata information about result type such as TypeId.
3. change as CreateVersion (establishment version), UpdateVersion (renewal version) etc. and follow the tracks of row
4. row of type special use (attribute of the type of statement)
5. the view of type special use (family's view) also comprises the object row that return object
The member of each type family can use a series of eye diagrams to search for, and each item types has a view in data storage.
A) project
Each project search view comprises delegation to each example of the project of particular type or its subtype.For example, the view of document can return the example of Document (document), LegalDocument (legal documents) and ReviewDocument (checking document).Given this example can such as shown in figure 28 generalities item eye diagram.
(1) master project search view
Each example definition of storage platform data storage is called the special item view of master project view (Master Item View).This view provides the survey information about each project in the data storage.View provides row to each item types attribute, a row description entry purpose type wherein, and some row are used to provide change to be followed the tracks of and synchronizing information. Item] " identify the master project view.
Row Type Describe
ItemId ItemId The storage platform identity of this project
_TypeId TypeId The definite type and being used to that the TypeId-of this project identifies this project uses metadata categories to retrieve information about type
RootItemId ItemId Control first non-embedding elder generation's of this purpose life cycle ItemId
<the overall situation changes follows the tracks of 〉 ... The overall situation changes trace information
<item attribute 〉 Do not have Each item types attribute there are row
(2) typed project search view
Each item types also has the search view.Although be similar to the root Element view, this view also provides by the visit of " _ Item " row to item objects.In data storage, use name [schema name] .[item types name] identify each typed project search view.[AcmeCorp.Dod] .[OfficeDoc for example].
Row Type Describe
ItemId ?ItemId The storage platform identity of this project
<type change is followed the tracks of 〉 ?... The type change trace information
<father attribute 〉 <attribute special use 〉 Each father's attribute there are row
<item attribute 〉 <attribute special use 〉 Each exclusive attribute to this type has row
Item The CLR type of project The type of the project of CLR object-statement
B) project expansion
All items expansion in the WinFs storage also can use the search view to visit.
(1) main expanded search view
Each example definition one of data storage is called the special extended view of main extended view (Master Extension View).This view provides the survey information about each expansion in the data storage.This view has row to each extended attribute, and wherein row are described the type of expansion, and some row are used to provide change to follow the tracks of and synchronizing information. Extension] " the main extended view of sign in data storage.
Row Type Describe
ItemId ItemId Expand the storage platform identity of related project therewith
ExtensionId ExtensionId(GUID) The id of this expansion example
_TypeId TypeId The TypeId-of this expansion identifies the definite type of this expansion, and can be used to use metadata categories to retrieve information about this expansion
<the overall situation changes follows the tracks of 〉 ... The overall situation changes trace information
<extended attribute 〉 <attribute special use 〉 Each expansion type attribute there are row
(2) typed expanded search view
Each expansion type also has the search view.Although be similar to main extended view, this view also provides by _ Extension and is listed as the visit to item objects. The expansion type name] identify each typed expanded search view. OfficeDocExt].
Row Type Describe
ItemId ItemId Expand the storage platform identity of related project therewith
ExtensionId ExtensionId(GUID) The Id of this expansion example
<type change is followed the tracks of 〉 ... The type change trace information
<father attribute 〉 <attribute special use 〉 Each father's attribute there are row
<extended attribute 〉 <attribute special use 〉 Exclusive attribute to each this type has row
Extension The CLR type of expansion example The type of the expansion of CLR object-statement
C) nested element
All nested elements are stored among project, expansion or the relationship example.Therefore, they can visit by inquiring about suitable project, expansion or relation search view.
D) relation
As above discuss, relation is formed on the elementary cell that links between projects in the storage platform data storage.
(1) primary relation search view
Each data storage provides a primary relation view.This view provides the information about all relationship example in the data storage. Relationship] " identify the primary relation view.
Row Type Describe
?ItemId ItemId The identity of source endpoint (ItemId)
?RelationshipId RelationshipId(GUID) The id of this relationship example
?_RelTypeId RelationshiPTypeId The RelTypeId-of this relation uses metadata categories to identify the type of this relationship example
<the overall situation changes follows the tracks of 〉 ... The overall situation changes trace information
?TargetItemReference ItemReference The identity of target endpoint
?_Relationship Relationship Example to the Relationship object of this example
(2) relationship example search view
The relation of each statement also has the search view of all examples that return this particular kind of relationship.Although be similar to the primary relation view, this view provides the row of name to each attribute of this relation data. Relation name] identify each relationship example search view. DocumentAuthor].
Row Type Describe
?ItemId ?ItemId The identity of source endpoint (ItemId)
?RelationshipId ?RelationshipId(GUID) The id of this relationship example
<type change is followed the tracks of 〉 ?... The type change trace information
?TargetItemReference ?ItemReference The identity of target endpoint
<parent name 〉 ?ItemId The name attribute of source endpoint identity (another name of ItemId)
<destination name 〉 The class of ItemReference or derivation The name attribute of target endpoint identity (another name of TargetItemReference and coercion of type conversion))
<attribute of a relation 〉 <attribute special use 〉 Attribute to each contextual definition has-Lie
?Relationship The CLR type of relationship example The type of CLR object-statement relation
9. upgrade
All views are read-only in the storage platform data storage.Be the new example of establishment data model elements (project, expansion or relation), or upgrade existing example, must use ProcessOperation or the ProcessUpdategram method of storage platform API.The ProcessOperation method is the process of single storage, and it is by the data definition storage of " operation " of the action that will carry out of consumption refinement.The ProcessUpdategram method is the process of storage, and it takes to be called one group of orderly operation of " more new element (updategram) ", the set that their common refinements will be carried out.
Operational format is extendible, and is provided at the various operations on the schema elements.Some common operation comprises:
1. project operation:
A.CreateItem (embedding or holding in the context of relation and create a new project)
B.UpdateItem (upgrading an existing project)
2. relational operation:
A.CreateRelationship (example of relation is quoted or held in establishment)
B.UpdateRelationship (upgrading a relationship example)
C.DeleteRelationship (removing a relationship example)
3. extended operation
A.CreateExtension (add one and expand to existing project)
B.UpdateExtension (upgrading an existing expansion)
C.DeleteExtension (deletion one expansion)
10. change and follow the tracks of and gravestone
More discuss fully as following, provide to change by data storage and follow the tracks of and the gravestone service.This section is provided at the general introduction of the change trace information that represents in the data storage
A) change tracking
Each the search view that is provided by data storage comprises the row that are used to provide the change trace information; Those row are public to all items, expansion and relational view.It is to provide indirectly by the search view that makes up view itself thereon that the storage platform mode view that is defined clearly by Design Pattern person does not automatically provide change trace information-this information.
Each element in the data storage can obtain changing trace information from two places: " master " element view and " typed " element view. Item] " and typed eye diagram [AcmeCorp.Document] .[Document] in obtain change trace information about the AcmeCorp.Document.Document item types.
(1) change in " master " search view is followed the tracks of
Change trace information in the main search view provide about the establishment of element and upgrade version information, about which synchronization partner create this element information, which synchronization partner to upgrade the information of this element for the last time and about from each partner's the version number creating and upgrade of being used to.Identify partner's (describing below) in the synchronized relation with partner's key.The single UDT object of by name _ ChangeTrackingInfo of type [System.Storge.Store] .ChangeTrackingInfo comprises all these information.Define styles in the System.Storage pattern.In all global search views of project, expansion and relation, can obtain _ ChangeTrackingInfo.The type definition of _ ChangeTrackingInfo is:
<Type?Name=″ChangeTrackingInfo″BaseType=″Base.NestedElement″>
<FieldProperty?Name=″CreationLocalTS″ Type=″SqlTypes.SqlInt64″
Nullable=″False″/>
<FieldProperty?Name=″CreatingPartnerKey″ Type=″SqlTypes.SqlInt32″
Nullable=″False″/>
<FieldProperty?Name=″CreatingPartnerTS″ Type=″SqlTypes.SqlInt64″
Nullable=″False″/>
<FieldProperty?Name=″LastUpdateLocalTS″ Type=″SqlTypes.SqlInt64″
Nullable=″False″/>
<FieldProperty?Name=″LastUpdatingPartnerKey″Type=″SqlTypes.SqlInt32″
Nullable=″False″/>
<FieldProperty?Name=″LastUpdatingPartnerTS″?Type=″SqlTypes.SqlInt64″
Nullable=″False″/>
</Type>
These attributes comprise following information:
Row Describe
CreationLocalTS The creation-time mark of local machine
_ CreatingPartnerKey Create the partner's of this entity PartnerKey.If entity is local the establishment, this is the PartnerKey of local machine
_ CreatingPartnerTS Locate to create the time mark of the time of this entity partner corresponding to _ CreatingPartnerKey
_ LastUpdateLocalTS Local zone time mark corresponding to update time of local machine
_ LastUpdatePartnerKey The last PartnerKey that upgrades the partner of this entity.If this locality that is updated in for the last time of this entity is finished, then this is the PartnerKey of local machine.
_ LastUpdatePartnerTS Locate to upgrade the time mark of the time of this entity partner corresponding to _ LastUpdatingPartnerKey.
(2) change in " typed " search view is followed the tracks of
Except provide with global search view identical information, each typed search view provides the additional information that is recorded in the synchronous regime of each element in the synchronous topology.
Row Type Describe
<the overall situation changes follows the tracks of 〉 ... Change the information of following the tracks of from the overall situation
_ChangeUnitVersions MultiSet<change unit version 〉 The description of the version number of the change unit in the element-specific
_ElementSyncMetadata ElementSyncMetadata About an additional version independent elements data to the interested project in synchronous operation storehouse
VersionSyncMetadata VersionSyncMetadata About only interested to the synchronous operation storehouse
The additional version dedicated meta data of version
B) gravestone
Data storage provides gravestone information for project, expansion and relation.The gravestone view provides in the place about living and the information of gravestone entity (project, expansion and relation).Project and expansion gravestone view do not provide the visit to corresponding objects, and concern that the gravestone view provides the visit to relationship object (relationship object is for empty under the situation of gravestone relation).
(1) project gravestone
Item] from system's search terms gravestone.
Row Type Describe
ItemId ItemId The identity of project
_TypeID TypeId The type of project
<item attribute 〉 ... Attribute to all items definition
_RootItemId ItemId The ItemId that comprises first non-embedding project of this purpose
_ChangeTrackingInfo The CLR example of ChangeTrackingInfo type This purpose changes trace information
_IsDeleted BIT This is a sign, the 0th, and the project of living, the 1st, gravestone project
_DeletionWallclock UTCDATETIME Press the partner's of delete items time on UTC wall clock date, if this project is alive, it is empty
(2) expansion gravestone
Extension] from system's retrieval expansion gravestone.Expansion changes the trace information interpolation that provides for project the has been provided information of ExtensionId attribute.
Row Type Describe
?ItemId ItemId The identity that has the project of this expansion
?ExtensionId ExtensionId The ExtensionId of this expansion
?_TypeID TypeId The type of this expansion
_ ChangeTrackingInfo The CLR example of ChangeTrackingInfo type The change trace information of this expansion
IsDeleted BIT This is a sign, the 0th, and the project of living, the 1st, gravestone expansion
_ DeletionWallclock UTCDATETIME During UTC wall clock day by the partner who deletes this expansion.If this expansion is alive, it is empty
(3) concern gravestone
Relationship] concern gravestone from system's retrieval.Concern the information that the gravestone info class is similar to be provided expansion.Yet, on the target ItemRef of relationship example, provide additional information.In addition, go back the choice relation object.
Row Type Describe
ItemId ItemId The identity (identity of the source endpoint of relation) that has the project of this relation
RelationshipId RelationshipId The RelationshipId of this relation
_ TypeID TypeId The type of relation
_ ChangeTrackingInfo The CLR example of ChangeTrackingInfo type The change trace information of this relation
IsDeleted BIT This is a sign, the 0th, and the project of living, the 1st, gravestone expansion
_ DeletionWallclock UTCDATETIME Press the partner's of this relation of deletion time on UTC wall clock date.If this relation is alive, it is empty
_ Relationship The CLR example of relation This is the relationship object of the relation of living, and gravestone concerned that it is for empty
TargetItemReference ItemReference The identity of target endpoint
(4) gravestone is removed
For preventing that gravestone information from unrestrictedly increasing, data storage provides gravestone to remove task.This task determines when can give up gravestone information.The boundary of the local establishment/renewal version of this task computation, and block gravestone information by giving up all gravestone versions more early subsequently.
11. assistant API and function
Base map also provides some Assistant Function.Provide these functions to help the common operation on this data model.
A) function [System.Storage] .GetItem
// given ItemId returns an item objects
Item?GetItem(ItemId?ItemId)
B) function [System.Storage] .GetExtension
// given ItemId and ExtensionId return an EXPANDING DISPLAY AREA
Extension?GetExtension(ItemId?ItemId,ExtensionId?ExtensionId)
C) function [System.Storage] .GetRelationship
// given ItemId and RelationshipId return-relationship object
Relationship?GetRelationship(ItemId?ItemId,RelationshipId?RelationshipId)
12. metadata
The metadata that has two classes in storage, to represent: instance metadata (type of project etc.), and genre metadata.
A) pattern metadata
The conduct of pattern metadata is stored in the data storage from the example of the item types of meta schema.
B) instance metadata
Application program use-case metadata is come the type of queried for items, and the expansion that is associated with project of searching.The ItemId of given project, application program can be inquired about the global keys eye diagram, returning the type of this project, and uses this to be worth and inquires about the Meta.Type view to return the information about the type of the statement of this project.For example,
// given project example is returned metadata project object
SELECT?m._Item?AS?metadataInfoObj
FROM[System.Storage].[Item]i?INNER?JOIN[Meta].[Type]m?ON?i._TypeId=m.ItemId
WHERE?i.ItemId=@ItemId
E. security
This section has been described the security model that is used for storage platform of the present invention according to an embodiment.
1. summarize
According to present embodiment, the granularity of specifying and putting teeth in the security strategy of storage platform is on the various operation levels on the project in given data storage; From integral body, do not protect the ability of the each several part of project discretely.This security model by access control list (ACL) specified can be awarded or denied access on project, to carry out the main body collection of these operations.Each ACL is the ordered set of ACE (ACE).
The security strategy that is used for project can be described by the access control policy of freely selecting and system's access control policy fully.These each is one group of ACL.First group (DACL) described the access rights of freely selecting of being authorized various main bodys by the owner of the project, and second group of ACL is called as SACL (system access control list), and it has specified how to finish system audit when with some mode manipulating objects.Except that these, each project in the data storage is associated with SID (owner SID) corresponding to the owner of the project.
Being used for organizing the main mechanism of project in the storage platform data storage is the mechanism that comprises hierarchy.Comprising hierarchy is to use the relation held between the project to realize.The relation of holding that is expressed as " A comprises B " between two project A and the B makes project A can influence the life cycle of item B.Generally speaking, the project in the data storage can't exist before the relation of holding that has from another project to this project.Except that control item purpose life cycle, the relation held provides the necessary mechanism of security strategy of the project of propagating.
For the security strategy of each project appointment by two parts forms-be this project clearly appointment part and in data storage from the part of father's project succession of this project.The security strategy of the clearly definition of any project is made up of-part of the visit of the Zhi pairing project in considering two parts, and influence is by the part that comprises the security strategy of all its descendants' successions in the hierarchy.The security strategy of being inherited by the descendants is to be decided by the strategy of clearly definition and the strategy of succession.
Because security strategy is propagated by holding relation, and also can be capped at any project place, therefore is necessary to specify the effective and safe strategy of how to identify project.In the present embodiment, data storage comprise in the hierarchy project along from the root of storage to each path inherited ACL of this project.
In the ACL that any given path is inherited, the ordering of each ACE among the ACL has determined to force real-time final security strategy.Following representation is used for describing the ordering of ACL ACE.The ordering of the ACE that inherits by project among the ACL by following two rules determine-
Article one, rule has satisfied the ACE that inherits from projects from the root that comprises hierarchy to the path of project I.The ACE that inherits from more approaching container has precedence over the clauses and subclauses of inheriting from container far away.On directly perceived, this allows the keeper can cover the ACE that inherits at a distance from comprise hierarchy.This rule is as follows:
Go up the ACL L of all successions for project I
For all items I1, I2
For all ACE A1 and A2 among the L
I1 is the ancestors of I2, and
I2 is the ancestors of I3, and
A1 is the ACE that inherits from I1, and
A2 is the ACE that inherits from I2
Mean
A2 has precedence over A1 in L
The second rule will be refused the ACE of the visit of project ordering before the ACE that authorizes the visit of project.
Go up the ACL L of all successions for project I
For all items I1
For all ACE A1 and A2 among the L,
I1 is the ancestors of I2, and
A1 is the ACCESS_DENIED_ACE that inherits from I1, and
A2 is the ACCESS_GRANTED_ACE that inherits from I1
Mean
A1 has precedence over A2 in L
Comprising under the situation of hierarchy for tree, have only a paths from the root of setting to this project, and this project has only the ACL of a succession.In these cases, according to the wherein relative ordering of ACE, be complementary by project ACL that inherits and the ACL that inherits by the file (project) in the existing Windows security model.
Yet the hierarchy that comprises in the data storage is directed acyclic graph (DAG), because project is allowed a plurality of relations of holding.In these cases, to project mulitpath is arranged from the root node that comprises hierarchy.Because project holds ACL along each path, so the set of each project and ACL but not single ACL are associated.Notice that these are different with traditional file system model, in this model, have only an ACL to be associated with file or folder.
When comprising hierarchy is DAG but not when tree to have two aspects to elaborate usually.Need to describe about how being its calculating effective and safe strategy when its father node is inherited an above ACL, and how to organize and the expression project has direct meaning for the management of the security model of storage platform data storage when project.
Following evaluation of algorithm one given main body is to the access rights of given project.In the entire chapter document, following representation is used to describe the ACL that is associated with project.
Inherited_ACLs (ItemId)-by its project identity project one group of ACL that his father's project is inherited from storage that is ItemId.
Explicit_ACL (ItemId)-for its identity be the ACL that the project of ItemID defines clearly.
NTSTATUS
ACLAccessCheck(
PSID pOwnerSid,
PDACL pDacl,
DWORD DesiredAccess,
HANDLE ClientToken,
PPRIVILEGE_SET?pPrivilegeSet,
DWORD *pGrantedAccess)
If the access rights of expectation are not refused clearly, then above-mentioned routine is returned STATUS_SUCCESS, and pGrantedAccess determines that in the authority of user expectation which authorized by the ACL of this appointment.If the expectation access rights are refused clearly, then this routine is returned STATUS_ACCESS_DENIED.
NTSTATUS
ItemAccessCheck(
OS_ITEMID ItemId,
DWORD DesiredAccess,
HANDLE ClientToken,
PPRIVILEGE_SET?pPrivilegeSet)
{
STATUS Status;
PDACL pExplicitACL=NULL;
PDACL pInheritedACLs=NULL;
DWORD NumberOflnheritedACLs=0;
pExplicitACL=GetExplicitACLForItem(ItemId);
GetInheritedACLsForItem(ItemId,&pInheritedACLs,&NumberOfInheritedACLs)
Status=ACLAccess?Check(
pOwnerSid,
pExplicitACL,
DesiredAccess,
ClientToken,
pPrivilegeSet,
&GrantedAccess);
if(Status!=STATUS_SUCCESS)
return?Status;
if(DesiredAccess==GrantedAccess)
return?STATUS_SUCCESS;
for(
i=0;
(i<NumberOfInheritedACLs&&?Status==STATUS_SUCCESS);
i++){
GrantedAccessForACL=0;
Status=ACLAccessCheck(
pOwnerSid,
pExplicitACL,
DesiredAccess,
ClientToken,
pPrivilegeSet,
&GrantedAccessForACL);
if(Status==STATUS_SUCCESS){
GrantedAccess|=GrantedAccessForACL;
}
}
If((Status==STATUS_SUCCESS)&&
(GrantedAccess!=DesiredAccess)){
Status=STATUS_ACCESS_DENIED;
}
return?Status;
}
The coverage of the security strategy that defines at arbitrary project place covers the descendants who comprises this project in the hierarchy who defines on the data storage.For all items that has defined explicit strategy, then effect is similar to definition by comprising the strategy that its all descendants inherited in the hierarchy.The effective ACL that is inherited by all descendants can be by getting the ACL that is inherited by this project, and the beginning that hereditable ACE among the explicit ACL adds this ACL to is obtained.But this is known as the inherited ACL collection that is associated with this project.
When root node when lack the explicit appointment of security comprising of file project place in the hierarchy, all descendants be applied to comprise this project in the hierarchy are specified in the security of file.Thereby, to its provide explicit security strategy appointment each project definition the zone of shielded project similarly, but and be the inherited ACL collection of this project for effective ACL of all items in this zone.Comprising under the situation that hierarchy is a tree, this is defined range intactly.If each zone all will be associated with a number, so only included the zone under the project just enough with this project.
Yet, so, comprise in the hierarchy effective and safe strategy and change residing point and generally determine by two intermediate item to the hierarchy that comprises of DAG.The first kind is the project of it having been specified explicit ACL.Usually, these are to comprise the point that keeper's explicitly is specified ACL in the hierarchy.Second class is to have an above father node, and each father node has the project with its different security strategies that are associated.Usually, these are the projects for the point of the security strategy of volume appointment, and have indicated the beginning of a new security strategy.
Adopt this definition, the projects in the data storage fall into one of two classifications-be those projects of the root node of shielded safety zone similarly, and are not those projects of this root node.The project of undefined safety zone generally only belongs to a safety zone.As under the situation of tree, the effective and safe of project can be specified by zone and this project under the technical routine.This causes a kind of flat-footed model that is used for coming based on each shielded similarly zone of storage the security of managed storage platform data storage.
2. the detailed description of security model
How this section influences various operations by each authority in the ACL that describes security descriptor and comprise provides about project protected details how.
A) security descriptor structure
Before describing the details of security model, be helpful about the basic discussion of security descriptor.But security descriptor comprises the security information that is associated with object of protection.Security descriptor is made of SECURITY_DESCRIPTOR (security descriptor) structure and the security information that is associated thereof.Security descriptor can comprise following security information:
1. the SID of the owner of object and main group.
2. the DACL of the access rights that allow or refuse is organized in appointment to specific user or user.
3. be appointed as the SACL of the type that visit that object generates audit record attempts.
4. limit one group of control bit of security descriptor or its indivedual member's implications.
Preferably, application program can not be manipulated the content of security descriptor directly.There is the function be used for being provided with the security information of the security descriptor of searching object.In addition, there is the function that is used to new Object Creation and initialization security descriptor.
The Access Control List (ACL) of freely selecting (DACL) but identified is allowed to or the bailee of denied access object of protection.But when process attempt visit object of protection, system verifies the ACE among the DACL of this object, determines whether its grant access rights.If this object does not have DACL, then system can authorize full access right to everyone.If the DACL of this object does not have ACE, the then attempt of this object of system's denied access is not because this DACL allows any access rights.System verifies ACE successively, up to one or more ACE of the all-access authority that finds permission to ask, or is rejected up to arbitrary access rights of asking.
System access control list (SACL) makes the keeper attempt of visit protected object can be charged to daily record.Each ACE has specified the type of an appointment bailee access attempts, and this access attempts system that makes generates a record in the security incident daily record.When access attempts failure, as its success or both, the ACE among the SACL can generate audit record.When unwarranted user figured for access rights for object, SACL proposed alarm.
All types of ACE comprise following access control information:
1. sign is used the bailee's of ACE secure identifier (SID) to it.
2. specify access mask by the access rights of this ACE control.
3. indicate the sign of the type of this ACE.
4. determine that can sub-container or object from one group of bit flag of the appended main object succession ACE of ACL.
But following form is listed three kinds of ACE types being supported by all object of protections.
Type Describe
Access reject ACE In DACL, use, in order to bailee's denied access authority.
Visit allows ACE In DACL, use, in order to allow access rights to the bailee.
System audit ACE In SACL, use, when attempting to exercise the access rights of appointment, be used to generate audit record as the bailee.
(1) access mask form
But all object of protections can use at the access mask form shown in Figure 26 and arrange its access rights.In this form, lower 16 are used for object private access authority, ensuing 7 standard access authorities that are used to be applied to most of type objects, the highest 4 are used to specify the generic access right that each object type can be mapped to one group of standard and the special-purpose authority of object.ACCESS_SYSTEM_SECURITY (access system safety) position is corresponding to the authority of the SACL of this object of visit.
(2) generic access rights
Specify in 4 most significant digits of generic authority in mask.Each class can be protected object these positions are mapped to one group standard and object private access authority.For example, a file object can be mapped to the GENERIC_READ position READ_CONTROL and SYNCHRONIZE standard access authority, and is mapped to FILE_READ_DATA, FILE_READ_EA and FILE_READ_ATTRIBUTES object private access authority.The object of other type is mapped to the GENERIC_READ position access rights group that is applicable to this class object.
When opening the handle of object, the generic access rights can be used for specifying required access type.This is simpler than all corresponding standards of appointment and special-purpose authority usually.Following form shows the constant into the generic access privileges definition.
Constant The generic implication
?GENERIC_ALL Reading and writing and execution visit
?GENERIC_EXECUTE Carry out visit
?GENERIC_READ Read access
?GENERIC_WRITE Write access
(3) standard access authority
Each class can be protected object has one group corresponding to the access rights to the operation of this class object special use.Except these object private access authorities, but also has one group corresponding to standard access authority to the public operation of the object of protection of most of types.Following form shows the constant into the standard access authority definition.
Constant Implication
DELETE The right limit of deletion object.
READ_CONTROL Read the authority of the information in the object security descriptor, do not comprise the information among the SACL.
SYNCHRONIZE Use this object to come synchronous authority.This can wait for up to this object thread to be in notified state.Some object type is not supported this visit authority.
WRITE_DAC The authority of DACL in the security descriptor of modification object.
WRITE_OWNER Possessory authority in the security descriptor of change object.
B) the special-purpose authority of project
In the access mask structure of Figure 26, the special-purpose authority of project is placed in the special-purpose authority section of object (lower 16).Because in the present embodiment, storage platform has represented two groups of API and has come management security-Win32 and storage platform API, must consider that therefore the special-purpose authority of file system object is to excite the design to the special-purpose authority of storage platform object.
(1) the special-purpose authority of file and directory object
Consider following table:
Catalogue Catalogue is described File File description Value
FILE_LIST_ DIRECTORY List the authority of the content of catalogue ?FILE_READ_?DATA Read the authority of corresponding file data 0x0001
FILE_ADD_FILE In catalogue, create the authority of file ?FILE_WRITE_?DATA Data are write the authority of file 0x0002
FILE_ADD_ SUBDIRECTORY Create the authority of sub-directory ?FILE_APPEND_?DATA Authority to the file appending data 0x0004
FILE_READ_EA Read the authority of extended file attributes ?FILE_READ_EA Read the authority of extended file attributes 0x0008
FILE_WRITE_EA Write the authority of extended file attributes ?FILE_WRITE_EA Write the authority of extended file attributes 0x0010
FILE_TRAVERSE The authority of traversal catalogue FILE_EXECUTE For this machine code file, carry out the authority of this document 0x0020
FILE_DELETE_ CHILD The authority of the All Files that deltrees and comprise Do not have Do not have 0x0040
FILE_READ_ ATTRIBUTES Read the authority of directory attribute FILE_READ_ ATTRIBUTES Read the authority of file attribute 0x0080
FILE_WRITE_ ATTRIBUTES Write the authority of directory attribute FILE_WRITE_ ATTRIBUTES The authority of written document attribute 0x0100
Table in the reference notices that file system made basic difference between file and catalogue, Here it is file and directory permission why can be on identical position overlapping reason.File system has defined the very authority of granular, thereby the permission application program is controlled at the behavior on these objects.For example, they allow application program to distinguish between attribute associated with the file (FILE_READ/WRITE_ATTRIBUTES), extended attribute and data stream.
The target of the security model of storage platform of the present invention is to simplify the right assignment model, therefore for example goes up application program operating in data storage project (contact person, Email etc.) and generally need not to distinguish between attribute, extended attribute and data stream.Yet for file and file, granularity Win32 authority is saved, and has defined the visit semanteme by storage platform, and making to provide compatibility with the Win32 application program.This mapping is discussed each project authority of following appointment.
Following project authority is to allow to operate appointment with what it was associated.The Win32 authority of each equivalence behind of these project authorities also is provided.
(2)WinFSItemRead
This authority allows the read access to all elements of project, comprises by embedding the project of relational links to project.It also allows to enumerate by holding the project (be also referred to as directoryof) of relational links to this project.This comprises the title of the project of relational links by reference.This permissions mapping arrives:
File:
(FILE_READ_DATA|SYNCHRONIZA)
File:
(FILE_LIST_DIRECTORY|SYNCHRONIZE)
Semanteme is that security application can be provided with WinFSItemReadData (WinFS project read data), and the specified right mask is the combination of the file permission of above appointment.
(3)WinFSItemReadAttributes
This authority allows the read access to the base attribute of project, and this file system that resembles very much between basic file attributes and the data stream is distinguished.Preferably, these base attributes are those attributes that reside in the elementary item of therefrom deriving all items.This permissions mapping arrives:
File:
(FILE_READ_ATTRIBUTES)
File:
(FILE_READ_ATTRIBUTES)
(4)WinFSItemWriteAttributes
This authority allows the write access to the base attribute of project, and this file system that resembles very much between basic file attributes and the data stream is distinguished.Preferably, these base attributes reside in those attributes in the elementary item of therefrom deriving all items.This permissions mapping arrives:
File:
(FILE_WRITE_ATTRIBUTES)
File:
(FILE_WRITE_ATTRIBUTES)
(5)WinFSItemWrite
The ability that this authority permission is write all elements of project comprises by embedding the project of relational links.This authority also allows to add or delete the ability of the embedding relation of other project.This permissions mapping arrives:
File:
(FILE_WRITE_DATA)
File:
(FILE_ADD_FILE)
In the storage platform data storage, as broad as long between project and file, because project also can have the relation of holding of other project in the data storage.Therefore, if having FILE_ADD_SUBDIRECTORY (or FILE_APPEND_DATA) authority, then can make project is source to the relation of other project.
(6)WinFSItemAddLink
This authority allows to add to the ability of the relation of holding of the project in the storage.It should be noted that, owing to be used for the security on a plurality of security model change projects of holding relation, and if from the higher point in the hierarchy, then change and to walk around WRITE_DAC, therefore on the project of destination, require WRITE_DAC can be created to its relation.This permissions mapping arrives:
File:
(FILE_APPEND_DATA)
File:
(FILE_ADD_SUBSIRECTORY)
(7)WinFSItemDeleteLink
Even this authority is in the ability of the relation of holding that does not also allow to delete this project when main body is authorized the authority of delete items.This is consistent with file system model, and helps to remove.This permissions mapping arrives:
File:
(FILE_DELETE_CHILD)-notice that file system is not equivalent to the file of this authority, but the notion that has to the relation of holding of other project has been arranged, and therefore also can realize this authority to non-file.
File:
(FILE_DELETE_CHILD)
(8) authority of delete items
Disappear if hold relation to last of project, then this project is deleted.Not to the explicit representation method of delete items.All that have a project of deleting are held the clear operation of relation, but it is more senior instrument and is not system's primitive.
If satisfy one of following two conditions, then use any project of path appointment can be cancelled link: (1) authorizes write permission along father's project in this path to this project, perhaps (2) this project on one's body standard rights mandate DELETE originally.When removing last and concern, this project disappears from system.If project is on one's body standard rights mandate DELETE originally, then use any project of ItemID appointment can be cancelled link.
(9) copy item purpose authority
If main body is authorized to the WinFSItemWrite on WinFSItemRead on the project and the destination document folder, then project can copy to the destination document folder from the source.
(10) authority of mobile project
Move only requires DELETE authority on the source file and the FILE_ADD_FILE on the catalogue of destination in file system, because it has preserved the ACL on the destination.Yet, can call at MoveFileEx in (MOVEFILE_COPY_ALLOWED) to specify and allow application program specify in to stride the sign of tolerable CopyFile semanteme under the situation that volume moves.For after moving, what having been taken place security descriptor four possible selections are arranged:
1. in file carries the volume of whole ACL-acquiescence, move semantic.
2. carry whole ACL and ACL is labeled as shielded with file.
3. only carry explicit ACE and cross over, and on the destination, inherit again.
4. do not carry anything, and move between the volume of succession-acquiescence again on the destination semantic-the same with xcopy.
In the safety model, if application program has been specified the MOVEFILE_COPY_ALLOWED sign, then to roll up interior and the volume between either way carry out the 4th option.If should specify by sign, then carry out second option, unless destination also in same safety zone (that is same successions semanteme).The storage platform level moves and also realizes the 4th option, and requires the READ_DATA on the source, with duplicate desired the same.
(11) check the authority of the security strategy on the project
If project is authorized standard rights READ_CONTROL to main body, then can check the security of project.
The authority of the security strategy on (12) the change project
If project is authorized standard rights WRITE_DAC to main body, then can change the security of project.Yet because data storage provides implicit expression to inherit, so this has the connotation that can how to change security on hierarchy.Rule is if the root mandate WRTIE_DAC of hierarchy then changes security strategy on whole hierarchy, no matter and the specific project in the hierarchy (or DAG) whether not to main body mandate WRITE_DAC.
(13) there is not the authority of direct equivalent
In the present embodiment, FILE_EXECUTE (FILE_TRAVERSE that is used for catalogue) does not have direct equivalent in storage platform.This model is compatible these authorities of preserving of Win32, but is not that project is made any access decision based on these authorities.As FILE_READ/WRITE_EA,, therefore do not provide this semanteme because the data storage project does not have the representation of extended attribute.Yet, keep this position for Win32 is compatible.
3. realize
The all items that defines same shielded zone has the clauses and subclauses that are associated with it in security table.Security table is defined as follows:
The project identity The orderly path of project Explicit project ACL Path A CL Zone ACL
Project identity clauses and subclauses are project identity of the root of same shielded safety zone.The orderly path of project is the orderly path (ordpath) that is associated with the root of same shielded safety zone.Explicit project acl entry is the explicit ACL for the root definition of same shielded safety zone.In some cases, this can be sky, for example, and when having a plurality of father's projects that belong to zones of different owing to project and define new safety zone.Path A CL is the ACL collection of being inherited by project, and regional acl entry is the ACL collection for the same shielded safety zone definition that is associated with project.
Calculating to the effective and safe of any project in the given storage has made full use of this table.For the security strategy of determining to be associated, obtain the safety zone that is associated with project, and retrieve the ACL that is associated with this zone with project.
When by the explicit ACL of direct interpolation or by indirect interpolation cause forming new safety zone hold the security strategy that relation changes with project is associated the time, making this security table keep up-to-date, is effective with the algorithm of guaranteeing the above-mentioned effective and safe that is used to identify project.
The various changes and the algorithm of enclosing of maintenance safe table to storage are as follows:
A) in container, create new projects
When new establishment project in container, its inherits all ACL that are associated with this container.Because the new project of creating has only father's project, so it and his father's project belong to the same area.Thus, need not in security table, to create new clauses and subclauses.
B) add explicit ACL to project
When ACL was added to project, it was that all its descendants that comprise the safety zone that belongs to identical with given project itself in the hierarchy define new safety zone.But belong to other safety zone in the hierarchy be the descendants's of given project all items for comprising, the safety zone remains unchanged, but the effective ACL that is associated with this zone is changed, to reflect the interpolation of new ACL.
Can trigger having a plurality of further defined ranges of all items of holding relation with the ancestors of the safety zone of crossing over old safety zone and redetermination the introducing of this new safety zone.For all such projects, need the new safety zone of definition, and repeat this process.
Figure 27 (a) and (b) are divided the new same shielded safety zone of coming out with (c) having described by introducing new explicit ACL from existing safety zone.This is to be indicated by the node that is labeled as 2.Yet, the introducing of this new region is caused creating other zone 3, because project has a plurality of relations of holding.
Below the renewal sequence of security table has been reflected decomposition to same shielded safety zone.
C) add the relation of holding to project
Hold when concern one of three kinds of possibilities of its initiation when adding to project.If hold the target of relation, the project in promptly considering is the root of safety zone, and then the effective ACL that is associated with this zone is changed, and need not the further modification to this security table.If it is identical with the safety zone of existing father's project of project newly to hold the safety zone in source of relation, then need not any change.Yet, if project has the father's project that belongs to different safety zones now, form new safety zone, with the root of given project as this safety zone.This change is transmitted to all items that comprises in the hierarchy by revising the safety zone that is associated with this project.Belong to consider in all items and the descendants in comprising hierarchy thereof of the identical safety zone of project all need to change.In case made change, needed to check that having a plurality of all items of holding relation further changes to determine whether needs.If any in these projects has father's project of different safety zones, then need further change.
D) hold relation from deletion of items
When holding from deletion of items when concerning,, may fold the safety zone with his father zone if satisfy some condition.More accurately, this can finish under the following conditions: (1) causes having the project of father's project and does not specify explicit ACL for this project if hold removing of relation; (2) cause all projects in same safety zone of his father's project if hold removing of relation, and be not the explicit ACL of this project definition.In these cases, these safety zones can be marked as identical with father's project.This mark need be applied to all items of its safety zone corresponding to the zone that is folded.
E) the explicit ACL of deletion from project
When the explicit ACL of deletion from project, may fold the safety zone of root with the safety zone of his father's project for this project.More accurately, if explicit ACL remove the project that causes its father's project in comprising hierarchy to belong to same safety zone, then can realize this process.In these cases, the safety zone can be labeled as identically, and change and to be applied to all items of its safety zone corresponding to the zone that is folded with father's project.
F) revise the ACL that is associated with project
In this situation, do not need security table is carried out any new interpolation.The effective ACL that is associated with this zone is updated, and this new ACL change is propagated into the safety zone that is influenced by it.
F. notify and change tracking
Press another aspect of the present invention, storage platform provides the notification capabilities that allows the application tracks data to change.This feature is mainly used for the application program that keeps the service logic on easy mistake state or the execution data change incident.Application program is registered in the notice on project, project expansion and the project relationship.After having submitted the data change to, notify and transmitted asynchronously.Application program can be filtered notice by project, expansion and relationship type and action type.
By an embodiment, storage platform API 322 provides two class interfaces for notice.The first, the application program registration changes incident by the simple data that the change to project, project expansion and project relationship triggers.The second, application program is created " supervisory programme " object and is come the group that concerns between monitor item, project expansion and the project.After time period above prolongation, can preserve and create again the state of supervisory programme object in thrashing or system off-line.Single notice can reflect a plurality of renewals.
1. store the change incident
This section provides the some the examples how notification interface that is provided by storage platform API 322 is provided.
A) incident
Project, project expansion and project relationship have represented by application program and have been used for the data change incident that log-on data changes notice.Following example code shows the definition of ItemModified on the Item base class (project modification) and ItemRemoved (project removes) button.onrelease.
// incident
public?event?ItemModifiedEventHandler? Item?ItemModified
public?event?ItemRemovedEventHandler? Item?ItemRemoved
All notices are all carried the project that enough data change with retrieval from data storage.Following example code shows the incident on the project of how registering, project expansion or the project relationship:
myItem.ItemModified+=new?ItemModifiedEventHandler(this.onItemUpdate);
myItem.ItemRemoved+=new?ItemRemovedEventHandler(this.onItemDelete);
In the present embodiment, storage platform is guaranteed if corresponding project is modified or deletes since last transmission notice, or under the situation of last new registration since from data storage, taking out with notification application.
B) supervisory programme
In the present embodiment, storage platform has defined and has been used for monitoring and (I) file or folder hierarchies structure, (2) project context, or the supervisory programme class of the object that is associated of (3) specific project.For in these three classifications each, storage platform provides the particular monitored program class that monitors the project, project expansion or the project relationship that are associated, for example, storage platform provides corresponding FolderItemWatcher (file project supervisory programme), FolderRelationshipWatcher (file concerns supervisory programme) and FolderExtensionWatcher (file expansion supervisory programme) class.
When creating supervisory programme, application program can be to the project that is pre-existing in, and promptly project, expansion or relationship request are notified.These option great majority are used to safeguard the application program of private keys height of eye speed buffer memory.If not request, then application program receives the notice of having created all renewals afterwards of supervisory programme object to occurring in.
Together with transmitting notice, storage platform provides " WatcherState (supervisory programme state) " object.WatcherState can be serialized and be kept on the disk.The supervisory programme state is used in failure subsequently or creates corresponding supervisory programme again after off-line when reconnecting.The new supervisory programme of creating again will regenerate unacknowledged notice.Application program is indicated sending to of notice by call " Exclude (the eliminating) " method quoted that provides notice on corresponding supervisory programme state.
Storage platform transmits the independent copy of supervisory programme state to each button.onrelease.The supervisory programme state that receives that calls subsequently at same button.onrelease is supposed sending to of all previous notices that receive.
As example, following example code shows the definition of FolderItemWatcher.
public?class?FolderltemWatcher:Watcher
{
// constructed fuction
public?FolderItemWatcher_Constructor(Folder?folder);
public?FolderItemWatcher_Constructor1(Folder?folder,Type?itemType);
public?FolderItemWatcher_Constructor2(ItemContext?context,ItemId?folderId);
public?FolderItemWatcher_Constructor3(Folder?folder,Type?itemType,
FolderItemWatcherOptions?options);
public?FolderItemWatcher_Constructor4(ItemContext?context,ItemId?folderId,Type?itemType);
public?FolderItemWatcher_Constructor5(ItemContext?context,ItemId,folderId,Type?itemType,
FolderItemWatcherOptions?options);
// attribute
public?ItemId?FolderItemWatcher_FolderId{get;}
public?Type?FolderItemWatcher_ItemType{get;}
public?FolderItemWatcherOptions?FolderItemWatcher_Options{get;}
// incident
public?event?ItemChangedEventHandler?FolderItemWatcher_ItemChanged;
}
Following example code shows file supervisory programme object how to create the content that is used for watch folder.Supervisory programme generates notice, i.e. incident when adding the existing music item of new music item or renewal or deletion.Particular file folder in the file supervisory programme watch folder hierarchy or All Files folder.
myFolderItemWatcher=new?FolderItemWatcher(myFolder,typeof(Music));
myFolderltemWatcher.ItemChanged+=new?ItemChangedEventHandler(this.onItemChanged);
2. change and follow the tracks of and the notice generting machanism
This storage platform provides a kind of simple and effective mechanism to come tracking data to change and has generated notice.Client computer is retrieved notice in the same connection that is used for retrieve data.This has simplified safety inspection largely, has removed time-delay and constraint on the possibility network configuration.Notice is retrieved by sending case statement.For preventing poll, client computer can be provided by " waiting for (the wairfor) " feature that is provided by database engine 314.Figure 13 shows basic storage platform notice notion.Can synchronously carry out etc. to be checked, in this case, invokes thread is blocked, and is available up to the result; Perhaps can carry out asynchronously, in this case, thread is not blocked, but and when result's time spent return results on independent thread.
The combination of " wait " and " selection " is attractive for monitoring that the data that are fit to the particular data scope change, and can monitor by the notice lock is set on corresponding data area because change.This is applicable to many common storage platform situations.Change for end item can monitor by the notice lock is set on corresponding data area.Change to file and folder tree can monitor by the notice lock is set on path domain.Change to type and subtype thereof can monitor by the notice lock is set on the type scope.
Generally speaking, have three with handle the different phases that notice is associated: (1) data change or even detect, (2) subscribe to coupling, and (3) notice is sent to.Get rid of synchronization notice and send to, promptly send to as the notice of a part of carrying out the affairs that data change, storage platform can realize that the notice of following two kinds of forms sends to:
1) direct event detection: carry out event detection and subscribe to the part that affairs are upgraded in the coupling conduct.Notice is inserted in the table that is monitored by the subscriber; And
2) event detection of Tui Chiing: after having submitted the renewal affairs to, carry out event detection and subscribe to coupling.Shi Ji subscriber or intermediary detect incident and generate notice subsequently.
Directly event detection requires to carry out extra code as a part of upgrading operation.This allows to catch all interested incidents, comprises the incident that the indication relative status changes.
The event detection of postponing removes to upgrading operation adds the requirement of additional code.Event detection is finished by final subscriber.The event detection of postponing is sent to event detection and incident usually and is carried out batch processing, and is applicable to that well the inquiry of database engine 314 (for example, SQL Server) carries out foundation structure.
The event detection of postponing depends on upgrades daily record or the tracking that operation stays.Storage platform is safeguarded one group of logical time mark and gravestone for the data items of deletion.When the change in the scan-data storage, client computer provides the time mark of the low watermark that definition is used to detect change and prevents one group of time mark repeating to notify.Application program may receive the notice that is changed that takes place after by the time of low watermark indication.
The complex application that can visit the core view also can be by creating special parameters and duplication filter table, optimizes and reduces the quantity of the required SQL statement of project that one group of supervision may be very big.Application program with specific demand is such as supporting the application program of enriching view can use available change tracking framework to come monitoring data to change and refresh its special-purpose snapshot.
Therefore, preferably, in one embodiment, storage platform realizes the time detecting method of postponement, as hereinafter more completely describing.
A) change tracking
Unique identifier is carried in all items, expansion and project relationship definition.Change is tracked as all data items and safeguards that one group of logical time mark writes down establishment, renewal and deletion time.The gravestone clauses and subclauses are used to represent the data items deleted.
Application program uses this information to have monitored since the last visit data storage of application program whether newly add, upgrade or deleted particular items, project expansion or project relationship effectively.Following example shows this mechanism.
create?table[item-extension-relationship-table-template](
identifier?uniqueidentifier?not?null?default?newid()
Created bigint, not null,--@@ deposits in when creating
Updated bignit, not null,--@@ deposits in when last the renewal
......
)
The project of all deletions, project expansion and relation are recorded in the corresponding gravestone table.A template illustrates as follows.
create?table[item-extension-relationship-tombstone?table-template](
identifier?uniqueidentifier?not?null,
Deleted bigint, not null,--@@ deposits in when deletion,
Created bigint, not null,--@@ deposits in when creating,
Updated bigint, not null,--@@ deposits in when last the renewal
......
)
Be efficiency reasons, storage platform is that project, project expansion, relation and pathname are safeguarded one group of global table.These global look-up table can be used for time mark and the type information that monitoring data scope effectively and retrieval are associated by application program.
B) time mark management
The logical time mark is for database storing, and promptly the storage platform volume is " local ".Time mark is monotonically increasing 64 place values.Keep single time mark and be enough to detect whether the data change has taken place after being connected to the storage platform volume the last time usually.Yet, in the most real situation, need to preserve more slightly time marks and check repetition.Reason is explained as follows.
The relevant database table is to be structured in one group of logical abstraction on the physical data structure, i.e. B tree, heap etc.Record distribution time mark to new establishment or renewal is not an atomic action.This record is inserted into the bottom data structure may be taken place in the different moment, and application program may see that record is unordered thus.
Figure 14 shows new record is inserted into two affairs in the same B tree.Because affairs T3 inserted its record before the insertion of scheduling affairs T2, the application program that therefore scans the B tree may be seen by being recorded in before the affairs of being inserted by T2 that affairs T3 inserts.Thus, the reader may suppose improperly that he has seen all records of creating before in the moment " 10 ".For addressing this problem, database engine 314 provides a kind of function of returning low watermark, before this low watermark, has submitted to all renewals and all more to be inserted in separately the bottom data structure in new capital.In above-mentioned example, the low watermark that returns is " 5 ", supposes that the reader started before submitting affairs T2 to.When allowing the data of application program in scan database or data area to change, the low watermark that is provided by database engine 314 determines to ignore which project effectively.Generally speaking, the ACID affairs are assumed that and continue the very short time that thus, the expection low watermark is in close proximity to nearest time of distributing mark.Under the situation of the affairs that have long duration, application program may must be preserved other time mark and be detected and abandon repetition.
C) data change detection-event detection
When data query was stored, application program obtained low watermark.Subsequently, application program uses this watermark to come its establishment in the scan-data storage, upgrade or delete the clauses and subclauses of time mark greater than the low watermark that returns.Figure 15 shows this process.
For preventing to repeat notice, application program is remembered the time mark greater than the low watermark that returns, and uses these time marks to come filtering to repeat.Application program is created the local temporary table of session, with effective reduction process one big group repetition time mark.Before sending case statement, application program is inserted all repetition time marks that before returned, and deletion is more as follows than the older time mark of returning of last low watermark.
delete?from?$dupilcates?where?ts<@oldLowWaterMarkI
insert?into?$duplicates(ts)values(...),...,(...);
waitfor(select*,getLowWaterMark()as?newLowWaterMark
from[global!items]
where?updated>=@oldLowWaterMark
and?updated?not?in(select*from?$duplicates))
G. synchronous
According to another aspect of the present invention, this storage platform provides synchronous service 330, it (I) allows a plurality of examples (each has the data storage 302 of oneself) of storage platform by one group of regular flexibly next each several part of their content synchronously, and (ii) provides foundation structure so that the data storage of storage platform of the present invention is synchronous with other data source that realizes proprietary protocol for the third party.
Storage platform takes place between one group of duplicate that participates in synchronously to storage platform.For example, with reference to figure 3, wish be mostly be provided under the control at another example of the storage platform of moving on the different computer systems between the data storage 302 of storage platform 300 and another remote data storage 338 synchronously.Total member's qualification of this group needn't be known by any given duplicate at any given time.
Different duplicate independently (concomitantly promptly) are made change.Synchronizing process is defined as makes each duplicate know the change of making by other duplicate.This synchronizing capacity is many main (multi-master) in essence.
Synchronizing capacity of the present invention allows each duplicate:
Determine what change another duplicate knows;
Request is about the information of the ignorant change of this duplicate;
Reception and registration is about the information of the ignorant change of other duplicate;
Determine when mutually conflict of two changes;
The local application changes;
Pass on conflict to decompose other duplicate to guarantee convergence; And
Decompose conflict based on the strategy that conflict is decomposed appointment.
Storage platform to storage platform synchronously
The main application of the synchronous service 300 of storage platform of the present invention is stores synchronized platform a plurality of examples of (each has its data storage).Synchronous service is in operation (rather than in the bottom table at database engine 314) on the storage platform pattern level.Therefore, for example " scope (Scope) " is used to define the synchronization group of discussing below.
Synchronous service is by the principle operation of " pure change (net change) ".Not record and send each operation (as transactional replication) that therefore synchronous service but send the net result of these operations often is merged into single net result with the result of a plurality of operations.
Synchronous service is not considered transaction boundaries usually.In other words, if in single affairs, the storage platform data storage is made two changes, do not guarantee that these change to be applied on all other duplicate-can to illustrate one atomically and change and other change is not shown.The exception of this principle is that if in same affairs same project is made two changes, then these changes guarantee to be sent and be applied to other duplicate atomically.Therefore, project is the consistency unit of synchronous service.
A) synchronous (Sync) controlling application program
Arbitrary application program can be connected to synchronous service and start synchronous operation.Such application program provides carries out all required parameters of (the synchronous overview of face as follows) synchronously.Such application program is called as synchro control application program (SCA) here.
When synchronous two storage platform examples, start synchronously by SCA in a side.This SCA notifies local synchronous service and remote partner synchronous.At opposite side, synchronous service is by being waken up by the message of sending from the synchronous service of initiating machine.(mapping that sees below) responds based on the persistent configuration information that exists on target machine for it.Synchronous service can be moved on schedule or in response to incident.In these cases, the synchronous service of realization timetable becomes SCA.
For enabling synchronously, need take two steps.At first, Design Pattern person must be with suitable synchronization semantics annotation storage platform model (as mentioned below appointment change unit).Secondly, synchronously must configuration (as described below) correctly on all machines with the example that participates in synchronous storage platform.
B) pattern note
The key concept of synchronous service is the notion that changes unit (Change Unit).Change the unit and be the schema fragment of the minimum of individually following the tracks of by storage platform.Each is changed the unit, and synchronous service can determine that it is changed or is not changed since synchronous for the last time.
Change unit in the designated mode reaches some purposes.At first, it has determined how online synchronous service is said another word.Make when changing in changing the unit, whole change unit is sent to other duplicate, because synchronous service does not know which part that changes the unit is changed.Secondly, it has determined the granularity of collision detection.When same change unit being made two concurrent changes (these terms are specific definition in follow-up chapters and sections), synchronous service causes conflict; On the other hand, make concurrent change, then do not have conflict and take place, and change is automatically merged if difference is changed the unit.The 3rd, it has seriously influenced the amount of the metadata that is kept by system.Each is changed the unit keep many synchronizing service metadatas; Therefore, make the littler meeting in change unit increase synchronous overhead.
Definition changes the unit need find out correct trading off.For this reason, synchronous service allows Design Pattern person to participate in this process.
In one embodiment, synchronous service is not supported the change unit greater than an element.Yet its supports to allow Design Pattern person specify the ability of the change unit littler than element-promptly, with a plurality of combinations of attributes of an element in independent change unit.In this embodiment, this is to use following sentence structure to realize:
<Type?Name=″Appointment″MajorVersion=″1″MinorVersion=″0″ExtendsType=″Base.Item″
ExtendsVersion=″1″>
<Field?Name=″MeetingStatus″Type=″the?storage?platformTypes.uniqueidentifier?Nullable=″False″/>
<Fileld?Name=″OrganizerName″Type=″the?storage?platformTypes.nvarchar(512)″Nullable=″False″/>
<Filed?Name=″OrganizerEmail″Type=″the?storage?platformTypes.nvarchar(512)″
TypeMajorVersion=″1″ MultiValued=″True″/>
...
<ChangeUnit?Name=″CU_Status″>
<Field?Name=″MeetingStatus″/>
</ChangeUnit>
<ChangeUnit?Name=″CU_Organizer″/>
<Field?Name=″OrganizerName″/>
<Field?Name=″OrganizerEmail″/>
</ChangeUnit>
...
</Type>
C) configuration synchronously
Wish to keep one group of synchronous storage platform partner of some part of their data to be called as synchronous community.Though the member of community wishes to keep synchronously, they need not represent data in identical mode; In other words, synchronization partner convertible they just in data in synchronization.
Under reciprocity situation, allow equity side to all their partner to keep the conversion mapping be unpractical.On the contrary, synchronous service is taked the method for definition " community's file ".Community's file is " Shared Folders " abstract of representing the synchronous with it hypothesis of all members of community.
The most handy example explanation of this notion.If Joe wishes to keep his My Documents (my document) file of some computing machines synchronous, Joe defines community's file, as is called JoeDocuments.On every computing machine, Joe is configuration one mapping between JoeDocuments file of supposing and local My Documents file subsequently.From this point, when the computing machine of Joe was synchronized with each other, they were talked by document among the JoeDocuments rather than their local project.With the method, the computing machine of all Joe is understood mutually, and needn't know whom other people is-and community's file becomes the general language of synchronous community.
The configuration synchronization service comprises three steps: (1) is defined in the mapping between local folders and the community's file; (2) definition determines which obtains synchronous synchronous overview (as synchronous with whom, and which subclass should be sent out, which is received); And the different synchronous overview of (3) definition timetable that should move, or manually move them.
(1) community's file-mapping
Community's file mapping is stored on the individual machine as the XML configuration file.Each mapping has following pattern:
/mappings/communityFolder
Community's file of this element name mapping.Name is followed the syntactic rule of file.
/mappings/localFolder
The local folders that this element name mapping is transformed into.This name is followed the syntactic rule of file.In order to make mapping effectively, file must exist.Project in this file be counted as to each this mapping synchronously.
/mappings/transformations
How this element definition is transformed into local folders and reverse conversion how with project from community's file.As if lacking or, not carrying out conversion for empty.Particularly, this means that no ID is mapped.This configuration is mainly used in the high-speed cache of creating file.
/mappings/transformations/mapIDs
The newly-generated local ident of this element request is endowed all projects from community's file mapping, rather than reuses the ID of community.ID mapping is safeguarded in the synchronous operation storehouse, since revolution change project.
/mappings/transformations/localRoot
All root Elements in this element request community file are as the sub-project of designated root.
/mappings/runAs
Whose this element is controlled at and authorizes the request of handling down at this mapping.If do not exist, then suppose the sender.
/mappings/runAs/sender
Exist this element to show that the sender of the message to this mapping must be impersonate, and under his voucher, handle request.
(2) overview
Overview is to separate required total parameter set synchronously synchronously.Provide it to the synchronous operation storehouse to start synchronously by SCA.Storage platform comprises following information to the synchronous synchronous overview of storage platform:
Local folders is as the source and target that changes;
Synchronous with it Remote Folder name-this file must be issued by shining upon as defined above from remote partner;
Direction-synchronous service support only sends, receives only and send-receives synchronously;
Local filter device-selection sends any local information to remote partner.Be expressed as the storage platform inquiry on the local folders;
Remote filter device-selection is retrieved what remote information-be expressed as storage platform inquiry on community's file from remote partner;
How conversion-definition is changed between project and native format;
Local security-appointment is to use from the change of remote endpoint retrieval under the permission of remote endpoint (personification), or the user starts in this locality synchronously; And
The conflict of conflict decomposition strategy-appointments be should be rejected, charge to daily record or decompose automatically-under latter event, specify and use which conflict resolver and its configuration parameter.
Synchronous service provides the Runtime Library CLR class that allows the synchronous overview of simple construction.Overview can be serialized into the XML file or from the serialization of XML file, so that storage (often with timetable) easily.Yet, in storage platform, do not store the standard place of all overviews; Welcome SCA on the point that needn't forever keep, to make up overview.Note, do not need to have local mapping and start synchronously.Can in overview, specify all synchronizing informations.Yet be the synchronization request that starts in response to by remote parties, need mapping.
(3) timetable
In one embodiment, synchronous service does not provide its scheduled basis structure.On the contrary, it depends on another assembly and finishes this task-available WindowsScheduler in Microsoft Windows operating system.Synchronous service comprises command line utility, and it takes on SCA and based on the synchronous overview triggering synchronous that is kept in the XML file.This utility routine makes on schedule or disposes Windows Scheduler operation in response to incidents such as logining or publish as the user and becomes very easy synchronously.
D) conflict is handled
Conflict in the synchronous service is handled and is divided into three phases: (1) occurs in collision detection-this step that changes when using and judges whether to use change safely; (2) automatically conflict decompose and charge to daily record-the consulting of this step (after occurring in and then collision detection) money automatically the conflict resolver with check whether conflict can be decomposed-Ruo can not, alternatively daily record is charged in conflict; And (3) conflict checks with decomposition-Ruo that some conflicts and is logged, and occurs in outside the environment of simultaneous session, takes then that this step-at this moment, the conflict that is logged can be decomposed and remove from daily record.
(1) collision detection
In the present embodiment, synchronous service detects two types conflict: based on the conflict of knowledge with based on the conflict that retrains.
(a) based on the conflict of knowledge
When two duplicate independently change same change unit, can cause conflict based on knowledge.If two changes are to carry out under situation about being ignorant each other, then to be called be independently-in other words in these two changes, and first version is covered by second knowledge, and vice versa.Based on the knowledge of as previously discussed duplicate, described synchronous service automatically detects all this conflicts, and handles these conflicts, and is as described below at this.
Sometimes, the bifurcated of conflict being thought change in the vncsion history of unit is helpful.If conflict does not take place in the life that changes the unit, then its vncsion history is exactly that a simple chain-each change all takes place in a back before.In the situation based on the conflict of knowledge, two change parallel the generation, make described chain splitting and become the version tree.
(b) based on the conflict that retrains
There is certain situation, in these cases, when being employed together, independently changing and violated integrity constraint.For example, two duplicate creating the file with same names in same directory can make such conflict take place.
Relate to two and independently change (as being used for) based on the conflict of constraint based on the conflict of knowledge; Yet they do not influence identical change unit.On the contrary, their influences are different to change the unit, but has constraint between them.
Synchronous service detects constraint violation when changing application, and causes the conflict based on constraint automatically.Decomposition requires to revise in the mode of not violating constraint the self-defined code of change usually based on the conflict of constraint; Synchronous service is not provided for finishing the general mechanism of this process.
(2) conflict is handled
When detecting conflict, synchronous service can be taked (being selected by the synchronous starter in the synchronous overview) in 3 actions: (1) refusal changes, and it is returned to the sender; (2) conflict is recorded in the conflict daily record; Perhaps (3) decompose conflict automatically.
If refusal changes, do not arrive described duplicate if change so, then synchronous service works.Negative Acknowledgement is sent out back starter.This decomposition strategy is mainly gone up useful at duplicate without a head (for example file server), the log record that wherein conflicts is infeasible.On the contrary, this duplicate forces other duplicate to change by refusal and handles conflict.
Starter disposes the conflict decomposition in its synchronous overview synchronously.Synchronous service is supported in and makes up a plurality of conflict resolvers-at first in the single overview by the following method, specifies the tabulation of conflict processor to attempt one by one, till one of them success; Secondly, the processor that will conflict is associated with the conflict type, for example, renewal-renewal is pointed to a conflict processor based on the conflict of knowledge, and daily record is pointed in other conflict with all.
(a) conflict is decomposed automatically
Synchronous service provides the conflict resolver of multiple acquiescence.This tabulation comprises:
It is local winning: if the data collision that stores with this locality then abandons and imports change into;
Long-range winning: as, then to abandon local data if conflict with importing into to change;
It is winning at last not write the person: any that select local winner or long-range winner based on the time mark that changes (notices that synchronous service does not rely on clock value usually; This conflict resolver is only exception for that rule);
Deterministic: as to select the winner to guarantee mode identical on all duplicate, but be not that an embodiment of significant in addition-synchronous service may use the lexicographic of Partner ID relatively to realize this feature.
In addition, ISV can realize and install its oneself conflict processor.Self-defined conflict processor can be accepted configuration parameter; This parameter must be specified by the SCA that the conflict of synchronous overview is decomposed in the part.
When the conflict resolver is handled conflict, it will need the tabulation (replacing conflict to change) of the operation carried out to return to working time.Then, long-range knowledge is suitably adjusted in these operations of sync service application, so that comprise the advised information of conflict processor.
May when using decomposition, detect another conflict.In this case, before carrying out original processing again, new conflict must be decomposed.
When the branch in the vncsion history of conflict being regarded as project, conflict is decomposed can be counted as contact-two branches of combination so that form independent point.Therefore, conflict is decomposed and is transferred vncsion history to directed acyclic graph (DAG).
(b) conflict log record
A kind of conflict processor of very particular type is a conflict log record device.Synchronous service is recorded in the daily record project as Type C onflictRecord with conflict.These the record conversely with the conflict project relevant (unless project itself is deleted).Each conflict record comprises: cause the change of importing into of conflict; The type of conflict: renewal-renewal, renewal-deletion, deletion-renewal, insertion-insertion, perhaps constraint; And the knowledge of importing the version and its duplicate of transmission of change into.The conflict of charging to daily record can be used for inspection as described below and decomposition.
(c) conflict is checked and is decomposed
Synchronous service is provided for Application inspection conflict daily record and the suggestion API to the decomposition method of wherein conflict.API allows application program to enumerate all conflicts or the conflict relevant with given project.It also allows these application programs to decompose the conflict that is logged with a kind of in 3 kinds of modes: (1) long-range winning-accept the change that is logged and cover afoul local the change; (2) local winning-ignore the conflict part of the change that is logged; And (3) suggestion is new, and change-wherein application program is advised a kind of merging, and this is incorporated in and decomposes described conflict in its view.In case decomposed conflict by application program, synchronous service is just deleted them from daily record.
(d) propagation of the convergence of duplicate and conflict decomposition
In the synchronization scenario of complexity, on a plurality of duplicate, can detect identical conflict.If this situation has taken place, then many things all may take place: (1) decomposes conflict on a duplicate, is sent to another and decompose; (2) on two duplicate, decompose conflict automatically; Perhaps (3) manually decompose conflict (checking API by conflict) on two duplicate.
In order to ensure convergence, synchronous service will be conflicted with decomposing and be passed to other duplicate.When the change of decomposing conflict arrived duplicate, synchronous service automatically found any conflict record that decomposes by this renewal in the daily record, and deletes them.In this case, the conflict on duplicate is decomposed and will be bundled on all other duplicate.
If for identical conflict, select different winners by different duplicate, the sync service application binding conflict principle of decomposing then, and automatically select and be better than alternative a kind of decomposition in two kinds of decomposition.Pick out the winner in the mode of determining, this determines that mode guarantees all to produce identical result (embodiment uses duplicate ID lexicographic relatively) in all.
If to identical conflict, " the new change " that different duplicate suggestions is different, then synchronous service is regarded this new conflict as special conflict, and uses conflict log record device to prevent that it from propagating into other duplicate.This situation can cause manual conflict decomposition usually.
To non-storage platform data storage synchronously
By storage platform of the present invention on the other hand, the architecture that storage platform provides ISV to be used to realize sync adapters, sync adapters make the storage platform can be with synchronous as legacy systems such as Microsoft Exchange, AD, Hotmail.Many synchronous service of being provided by following synchronous service are provided sync adapters.
No matter its title how, sync adapters does not need to realize as the plug-in unit of certain storage platform architecture.When needed, " sync adapters " can be to utilize synchronous service Runtime Library interface to obtain to enumerate and the Any Application of service such as application as change simply.
For make other people can more easily dispose and run to given rear end synchronously, encourage the author of sync adapters to represent standard sync adapters interface, operation is synchronously when given above-mentioned synchronous overview for it.Overview provides configuration information to adapter, adapter with some information be sent to the synchronous operation storehouse with control Runtime Library service (as, synchronous file).
A) synchronous service
Synchronous service provides some synchronous service to the adapter author.At this section remaining part, easily storage platform is finished synchronous machine thereon and be called " client computer ", and adapter just is called " server " with the non-storage platform rear end of its dialogue.
(1) change is enumerated
Based on the change tracking data of being kept by synchronous service, change is enumerated and is allowed sync adapters easily to enumerate the change that since last and this partner attempt to make synchronously the data storage folder has been taken place.
Enumerate based on the notion of " anchor point " that change-this is the opaque structure of relevant last the hyposynchronous information of expression.As described in former chapters and sections, anchor point is taked the form of storage platform knowledge.Utilize the sync adapters that changes the service of enumerating to fall into two big classifications: the adapter of " anchor point of storage " and the adapter of use " anchor point that provides " are provided.
Difference based on about last hyposynchronous information stores where-on the client computer still on server.Adapter usually easily store this information on client computer-this information often can not easily be stored in the rear end.On the other hand, if a plurality of client computer and same backend synchronization, then on client computer be with this information stores poor efficiency and be in some cases incorrect-this makes a client computer not know that other client computer shifted the change of server onto.If adapter wishes to use the anchor point of server stores, then adapter need send back to storage platform with it when change is enumerated.
In order to allow storage platform safeguard anchor point (being used for the Local or Remote storage), storage platform need be known the change that successfully is applied on the server.These and have only these changes to be included in the anchor point.During change was enumerated, sync adapters was used and is confirmed (Acknowledgement) interface, was successfully used to report which changes.With EOS the time, the adapter of the anchor point that use provides must be read new anchor point (it combines the change of all successful Application) and send it to their rear end.
Each adapter usually needs the storage adapter exclusive data and is inserted into projects in the storage platform data storage.The common examples of this data storage is remote ident and remote version (time mark).Synchronous service is provided for storing the mechanism of these data, and changes the mechanism that the change that receives this excessive data and will return is provided of enumerating.In most of the cases, this has eliminated the adapter demand of Query Database again.
(2) change application
Change is used the change that allows sync adapters to receive from their rear end and is applied to local storage platform.The expectation adapter is transformed into the storage platform pattern with change.
Changing the major function of using is to detect conflict automatically.As under the storage platform situation synchronous to storage platform, two overlapping changes that conflict is defined by making when not knowing mutually.When adapter used change to use, they must specify the anchor point of it being carried out collision detection.Change if detect the overlapping this locality that is not covered, then change application and cause conflict by the knowledge of adapter.Be similar to change and enumerate, anchor point storage or that provide can be provided adapter.Change effective storage of application program support adapter dedicated meta data.Such data can be appended to it in the change that will use by adapter, and can be stored by synchronous service.Data can change in next time to be returned when enumerating.
(3) conflict is decomposed
Above-mentioned conflict is decomposed mechanism (comprise log record and decompose option automatically) and also can be used sync adapters.When use changing, sync adapters can be specified the strategy of the decomposition that is used to conflict.If specify, then conflict can be passed to the conflict handling procedure of appointment and be decomposed (if possibility).Conflict also can be logged.When attempting that this locality is changed when being applied to the rear end, adapter can detect conflict.Under such situation, adapter still can be delivered to conflict the synchronous operation storehouse, to decompose by strategy.In addition, sync adapters can ask any conflict that is detected by synchronous service to send back to them so that handle.Can store or decompose that this is convenient especially under the situation of conflict in the rear end.
B) adapter is realized
Though some " adapter " is the application program of utilizing the Runtime Library interface simply, yet encourage adapter to realize the adaptor interface of standard.These interfaces allow the synchro control application program: the request adapter is carried out synchronously by given synchronous overview; It is synchronous that cancellation is just being carried out; And receive about just carrying out synchronous progress report (Percent Complete).
3. security
Synchronous service is made great efforts the least possible being incorporated into synchronously in the safe mode that is realized by storage platform.Not the authority new, and be to use existing authority synchronous definition.Particularly,
Anyone of energy read data stored items can enumerate the change to this project;
Anyone that can write the data storage project can use to this project and change; And
Anyone of energy growth data stored items can be with synchronizing metadata and this item association.
Synchronous service is the maintenance safe authorization message not.When making change at duplicate A by user U, and when it was forwarded to duplicate B, this change had been lost in the fact that A place (by U) makes at first.If B is forwarded to duplicate C with this change, then this is to finish under the mandate of B rather than the mandate at A.This just causes following restriction: if distrust a duplicate that a project is made its change, it can not transmit the change of being made by other duplicate.
When starting synchronous service, finish by the synchro control application program.The identity of synchronous service personification SCA, and under this identity, finish all operations (local with long-range).As an illustration, observe the change that user U can not make local synchronous service from the retrieval of remote storage platform user U not had the project of read access.
4. manageability
The distributed community that monitors duplicate is a complicated problems.Synchronous service can be used " scanning " algorithm to collect and distribute information about the state of this duplicate.The attribute of scanning algorithm guarantee about to some extent the information of duplicate of configuration finally be collected, and detect the duplicate of this failure (not having response).
On each duplicate, can obtain the monitor message of community's scope.Can be on the duplicate of choosing arbitrarily the operation monitoring instrument, to check this monitor message and to make management decision.On affected duplicate, must directly make configuration change.
G. traditional file interoperability
As above mention, at least in certain embodiments, storage platform of the present invention is intended to be implemented as the integral part of the hardware/software interface system of computer system.For example, storage platform of the present invention can be implemented as the operating system integral part as Microsoft Windows family operating system.In this respect, storage platform API becomes the part of operating system API, and application program is mutual by it and operating system.Therefore, storage platform becomes device, and application program is deposited information on the operating system by it, thereby and the data model of project-based storage platform substituted the traditional file systems of this operating system.For example, when in Microsoft Windows family operating system, implementing, the alternative new technology file system of in this operating system, realizing of storage platform.Current, application program visits the service of new technology file system by the Win32 API that is represented by Windows family operating system.
Yet, will be appreciated that, substitute new technology file system with storage platform of the present invention fully and need the existing application program of recompile based on Win32, and such recompile may be undesirable, therefore storage platform of the present invention provide with certain interoperability as existing file systems such as NTFS be useful.Thereby in one embodiment of the invention, storage platform makes the application program that depends on the Win32 programming model can visit the data storage of storage platform and the content of traditional new technology file system simultaneously.For this reason, storage platform uses naming convention as the superset of Win32 naming convention so that be easy to interoperability.In addition, the storage platform support is stored in file and catalogue in the storage platform volume by the Win32 API Access.
1. interoperability model
According to this one side of the present invention, and according to above-mentioned exemplary embodiment, storage platform has realized a kind of name space, wherein can organize non-file and docuterm.Adopt this model, can obtain following advantage:
1. but file include file in the data storage and non-docuterm are that the data of file and medelling have presented single name space thus.In addition, it also provides same safe, shared and administrative model for all customer data.
2. because file and non-docuterm all can use storage platform API to visit, and in this method not for file applies special rules, so it comes work for application developer has proposed a kind of clearer programming model.
3. storage platform is all passed through in all name space operations, and is therefore synchronously handled.Be important to note that the attribute of deep layer upgrading (dispersing of file content) still takes place asynchronously, but synchronous operation provides more predictable environment for user and application program.
As the result of this model, in the present embodiment, may on the data source that is integrated into the storage platform data storage, not provide search capability.This comprises the file on removable media, remote server and the local disk.Provide to residing in the sync adapters of the acting server project (metadata of shortcut+upgrading) in the project demonstration storage platform in the foreign file system.The acting server project does not attempt to imitate file according to the name space level or the security of data source.
The passing that the symmetry that realizes on name space between file and the non-file content and programming model provides application program to be used in time will be from the content transplanting of the file system better path to the more structurized project of storage platform data storage.By the type of this machine docuterm in the storage platform data storage is provided, application program can be transferred to storage platform with file data, still can handle this data by Win32 simultaneously.Finally, application program may be transplanted to storage platform API fully, and according to storage platform items but not file comes its data of structuring.
2. data storage feature
For the interoperability grade of expectation is provided, in one embodiment, realize the following feature of storage platform data storage.
A) non-volume
The storage platform data storage is not presented as independent file system volume.Storage platform has made full use of the FILESTREAM of direct main memory on NTFS.Thus, not to coiling the change of form, eliminated the demand that storage platform is presented as new file system in the volume level thus.
On the contrary, data storage (name space) is rolled up corresponding to NTFS and is constructed.This partial data storehouse and the FILESTREAM that retreat name space are positioned on the NTFS volume that is associated with the storage platform data storage.Data storage corresponding to system volume also is provided.
B) storage organization
The most handy example of structure of storage illustrates.As an example, the directory tree on the system volume of the machine of consideration HomeMachine by name, as shown in figure 16.According to file system interoperability feature of the present invention, corresponding to c: drive, exist UNC to share the storage platform data storage that represents to Win32 API by for example being called " WiinFSOnC ".This makes the data storage that is associated to visit by following UNC name:
\\HomeMachine\WinFSOnC。
In this embodiment, file and/or file need be transplanted to storage platform from the NTFS explicitly.Therefore, if the user wishes My Documents file is moved to the storage platform data storage so that all extra search/characteristic of divisions that provided by storage platform to be provided, then this hierarchy will be as shown in figure 17.Be important to note that these files are actual in this example to be moved.Another point is noted that name space moves in the storage platform, and actual stream is by RNTO FILESTREAM, at the suitable pointer of storage platform inner hanging hook.
C) do not transplant All Files
Corresponding to user data or to need the file of search/classification that storage platform provides be the candidate of being transplanted to the storage platform data storage.Preferably, be the application compatibility problem of restriction with storage platform, in the context of MicrosoftWindows operating system, this group file of being transplanted to storage platform of the present invention is limited to the Desktop.ini file in file, Internet Explorer (IE) Favorites, IE History and the Documents and Settings catalogue in the MyDocuments file.Preferably, it is unallowed transplanting the Windows system file.
D) the NTFS name space of storage platform file is visited
Among the described herein embodiment, the file that storage platform is transplanted in expectation can not visit by the NTFS name space, even actual file stream stores with NTFS.In this way, avoided realizing that by multithreading the complexity that causes locks and safety issue.
E) Qi Wang name space/drive letter
To the visit of file in the storage platform and file be by<machine name<the WinFS shared name UNC name of form provides.Be used for the application program operating class for the needs drive letter, drive letter can be mapped to this UNC name.
I. storage platform API
As mentioned above, storage platform comprises API, and it makes application program can visit the feature and the ability of storage platform discussed above, and visit is stored in the project in the data storage.This section is described the embodiment of the storage platform API of storage platform of the present invention.
Figure 19 illustrates the basic architecture by the storage platform API of present embodiment.Storage platform API uses SQL client computer 1900 and local datastore 302 dialogues, and also uses SQL client computer 1900 and long-range number storage (as data storage 340) dialogue.Local storage also can be used DQP (Distributed Query Processing device) or talk with by above-mentioned storage platform synchronous service (" Sync ") and remote data storage 340.Storage platform API322 also takes on the bridge API of data storage notice, the subscript of application program is sent to notification engine 332, and as mentioned above notice is routed to application program (as application program 350a, 350b or 350c).In one embodiment, storage platform API 322 also defines restricted " supplier " architecture, makes it can visit data among Microsoft Exchange and the AD.
1. summarize
The data access mechanism of the present embodiment of storage platform API of the present invention has solved four fields: inquiry, navigation, action, incident.
Inquiry
In one embodiment, the storage platform data storage realizes on relevant database engine 3 14; As a result, the complete expressivity ability of sql like language is intrinsic in storage platform.More senior query object provides the simplified model that is used to inquire about storage, but may not encapsulate the complete expressivity ability of storage.
Navigation
The storage platform data model has made up a kind of abundant, extendible type system on underlying database is abstract.For the developer, the storage platform data are nets of project.Storage platform API allows to navigate between project by filtration, relation, file etc.This is than more senior abstract of basic SQL inquiry; Simultaneously, it allows the CLR coding mode of being familiar with is used abundant filtration and homing capability.
Action
Storage platform API represents action-Create public on all items (establishment), Delete (deletion), Update (renewal); These are presented as the method on the object.In addition, also can use such as SendMail (transmission mail), CheckFreeBusy territory dedicated action such as (checking idle and busy) as method.The API framework uses ISV to can be used for the pattern of adding the good definition of value by the definition additional move.
Incident
Data in the storage platform are dynamic.Make a response when the data of application program in storage are changed, API has represented abundant incident, subscription and notification capabilities to the developer.
2. name and scope
It is useful distinguishing between name space and name.As commonly used, the term name space refers to the set of all available in a certain system names.System can be set of XML pattern, program, web, all ftp websites (and content) or the like.Name is to be used in name space all item of interest to distribute the process or the algorithm of unique name.Thus, name is interested, because expectation Wu Qi free burial ground for the destitute relates to the given unit in the name space.Thus, as used herein, term " name space " refers to the set of all available names in all storage platform examples in the universe.Project is the named entity in the storage platform name space.The UNC naming convention is used to guarantee the project uniqueness of name.Each project in the universe in each storage platform storage can be come addressing by the UNC name.
Maximum tissue rank in the storage platform name space is that service-it only is an example of storage platform.The next stage of tissue is a volume.Volume is the maximum anonymous container of project.Each storage platform example comprises one or more volumes.In volume is project.Project is the data atom in the storage platform.
Data in the real world are almost always organized according to significant a certain system in given field.Under all such data organization patterns is the notion that the universe of data is divided into the name group.As mentioned above, this notion is come modeling by the notion of file in storage platform.File is a kind of project of specific type; Two types file is arranged: include file folder and virtual folder.
With reference to Figure 18, include file folder is a project, and it comprises the relation of holding with other project, and with the file system folder equivalence of common notion.Each project " comprises " at least one include file folder.
Virtual folder is a more dynamic approach of organizing project set; It only is that name-this group project of given one group of project is that explicitly is enumerated or by the inquiry appointment.Virtual folder itself is a project, and can be considered to represent that one group (non-holding) with one group of project concerns.
Sometimes, need carry out modeling to the tightr notion that comprises; For example, be embedded in the email message Word document in some sense ratio more closely be tied to its container as the file that is included in the file.This notion is to be expressed by the notion of the project of embedding.The embedding project has a kind of special relation, and it quotes another project; The project of quoting can only be tied to and comprise project or only handle in comprising the context of project.
At last, storage platform provides the mode of the notion conduct of classification to the classification of project and element.Each project in the storage platform or element can have the one or more classifications that are associated with it.Classification just is tagged to the name on project/element in essence.This name can be used in search.The storage platform data model allows the hierarchy of definition classification, thereby allows the tree-shaped classification of data.
A kind of name of not having qi justice of project is a tlv triple: and (<Service name 〉,<volume ID 〉,<item id 〉).Some project (especially file and virtual folder) is the set of other project.This causes a kind of identification item purpose substitute mode: and (<Service name 〉,<volume ID 〉,<item Path 〉).
The storage platform name comprises the notion of service context: service context is to be mapped to (<file label 〉,<path 〉) right name.It has identified a project or one group of project-for example, file, virtual folder etc.For service context, the UNC name that is used for any project of storage platform name space becomes:
<Service name<service context<item Path
User creatable and deletion service context.Equally, the root directory in each volume has predefined context: file label $.
The scope of (for example, search operation) inquired about calmly in the project context by the result that restriction returns to the project of survival in specified path.
3. storage platform API assembly
Figure 20 schematically shows the various assemblies according to the storage platform API of present embodiment of the present invention.Storage platform API comprises following assembly: (1) data class 2002, and it represents storage platform element and item types; (2) the Runtime Library framework 2004, the persistence of its management object and the class 2006 that provides support; And (3) instrument 2008, it is used for generating the CLR class from the storage platform pattern.
According to one aspect of the present invention, when design, the code 2012 that pattern author submits schema document 2010 to and is used for the territory method to instrument 2008 when one group of storage platform API design.These instruments generate the storage class definition 2016 of client-side data class 2002 and memory module 2014 and this pattern." territory " refers to specific pattern; For example, talk about the territory method or the like of the class in the contact schema.These data class 2002 are cooperated with making with storage platform API Runtime Library framework class 2006 by application developer in when operation and are used for handling the storage platform data.
For the each side of storage platform API of the present invention is described, some examples have been presented based on the example contacts pattern.The diagram of this exemplary patterns is illustrated in shown in Figure 21 A and the 21B.
4. data class
According to an aspect of of the present present invention, each project in the storage platform data storage, project expansion and element type and each pass tie up to has corresponding class among the storage platform API.Haply, the field mappings of type is to the field of class.Each project in the storage platform, project expansion and element can be used as the object of the corresponding class among the storage platform API.The developer can inquire about, creates, revises or delete these objects.
Storage platform comprises one group of originate mode.Each mode-definition one group of project and element type, and one group of relation.Below be an embodiment who is used for generating the algorithm of data class from these pattern entities:
For each Mode S:
For each the project I among the S, generate the class of System.Storage.S.I by name.Such has following member:
The constructed fuction of heavy duty comprises allowing to specify the original document folder of new projects and the constructed fuction of name.
The attribute of each field among the I.If field is many-valued, then attribute will be the set of the element type of correspondence.
Find out the static method method of (for example, by name " FindAll ") of heavy duty of a plurality of projects of matching filter.
Find out the static method method of (for example, by name " FindOne ") of heavy duty of the single project of matching filter.
Given its ID finds out the static method (for example, the method for " FindByID " by name) of project.
Given its found out the static method (for example, the method for " FindByName " by name) of project with respect to the contextual name of project.
Preservation is to the method (for example, the method for " Update " by name) of the change of project.
The static Create method of the heavy duty of the new example of establishment project.These methods allow the original document folder of technical routine in every way.
For each the element E among the S, generate the class of System.Storage.S.E by name.Such has following member:
The attribute of each field among the E.If field is many-valued, then attribute will be the set of the element type of correspondence.
For each the element E among the S, generate the class of System.Storage.S.ECollection by name.Such follows the general .NET framework policy of the collection class that is used for strong typing.For the element type based on relation, such also will comprise following member:
Find out the method for heavy duty of a plurality of objects that coupling implicitly comprises the project of the filtrator that wherein is integrated into the project that occurs in the source case.Heavy duty comprises permission some method (for example, the method for " FindAllTargetItems " by name) based on the filtration of project subtype.
Find out the method for heavy duty that coupling implicitly comprises the single item objects of the filtrator that wherein is integrated into the project that occurs in the source case.Heavy duty comprises some method (for example, the method for " FindOneTargetItem " by name) that permission is filtered based on project subtype.
Find out the method method of (for example, by name " FindAllRelationships ") of heavy duty of object that coupling implicitly comprises the nested element type of the filtrator that wherein is integrated into the project that occurs in the source case.
Find out the method (for example, by name " FindAllRelationshipsForTarget " method) of heavy duty of object that coupling implicitly comprises the nested element type of the filtrator that wherein is integrated into the project that occurs in the source case.
Find out the method method of (for example, by name " FindOneRelationship ") of heavy duty of single object that coupling implicitly comprises the nested element type of the filtrator that wherein is integrated into the project that occurs in the source case.
Find out the method method of (for example, by name " FindOneRelationshipForTarget ") of heavy duty of single object that coupling implicitly comprises the nested element type of the filtrator that wherein is integrated into the project that occurs in the source case.
For the R that concerns among the S, generate the class of System.Storage.S.R by name.Such has one or two subclass, depends on that one or two relationship roles have specified end-points field.
Also can be that class is created in each project expansion of being created in this way.
Data class is present in System.Storage.<schema name〉in the name space, wherein<and schema name〉be the name-such as Contacts (contact person), Files (file) etc. of corresponding pattern.For example, corresponding to all classes of contact schema in the System.Storage.Contacts name space.
As example, with reference to figure 21A and 21B, contact schema cause being included in the System.Storage.Contact name space with lower class:
Project: Item, Folder, WellKnownFolder, LocalMachineDataFolder, UserDataFolder, Principal, Service, GroupService, PersonService, PresenceService, ContactService, ADService, Person, User, Group, Organization, HouseHold
Element: NestedElementBase, NestedElement, IdentityKey, SecurityID, EAddress, ContactEAddress, TelephoneNumber, SMTPEAddress, InstantMessagingAddress, Template, TemplateRelationship, LocationRelationship, FamilyEventLocationRelationship, HouseHoldLocationRelationship, RoleOccupancy, EmployeeData, GroupMemberShip, OrganizationLocationRelationship, HouseHoldMemberData, FamilyData, SpouseData, ChildData
As another example, illustrate as follows with XML as the detailed structure of the Person type that in contact schema, defines:
<Type?Name=″Person″MajorVersion=″1″MinorVersion=″0″
ExtendsType=″Core.Principa|″ExtendsVersion=″1″>
<Field?Name=″Birthdate″Type=″the?storage?platformTypes.datetime″
Nullable=″true″TypeMajorVersion=″1″/>
<Field?Name=″Gender″Type=″Base.CategoryRef″
Nullable=″true″MultiValued=″false″
TypeMajorVersion=″1″/>
<Field?Name=″PersonalNames″Type=″Contact.FullName″
Nullable=″true″MultiValued=″true″
TypeMajorVersion=″1″/>
<Field?Name=″PersonalEAddresses″Type=″Core.EAddress″
Nullable=″true″MultiValued=″true″
TypeMajorVersion=″1″/>
<Field?Name=″PersonalPostalAddresses″
Type=″Core.PostalAddress″Nullable=″true″
MultiValued=″true″TypeMajorVersion=″1″/>
<Fjeld?Name=″PersonalPicture″Type=″the?storage?platformTypes.image″
Nullable=″true″TypeMajorVersion=″1″/>
<Field?Name=″Notes″Type=″Core.RichText″Nullable=″true″
MultiValued=″true″TypeMajorVersion=″1″/>
<Field?Name=″Profession″Type=″Base.CategoryRef″
Nullable=″true″MultiValued=″true″
TypeMajorVersion=″1″/>
<Field?Name=″DataSource″Type=″Base.IdentityKey″
Nullable=″true″MultiValued=″true″
TypeMajorVersion=″1″/>
<Field?Name=″ExpirationDate″Type=″the?storage?platforrmTypes.datetime″
Nullable=″true″TypeMajorVersion=″1″/>
<Field?Name=″HasAllAddressBookData″Type=″the?storage?platformTypes.bit″
Nullable=″true″TypeMajorVersion=″1″/>
<Field?Name=″EmployeeOf″Type=″Contact.EmployeeData″
Nullable=″true″MultiValued=″true″
TypeM?ajorVersion=″1″/>
</Type>
The type causes with lower class (only showing publicly-owned member):
partial?public?class?Person:
System.Storage.Core.Principal,
System.Windows.Data.IDataUnit
{
public?System.Data.SqlTypes.SqlDateTime
Birthdate{get;set;}
public?System.Storage.Base.CategoryRef
Gender{get;set:}
public?System.Storage.Contact.FullNameCollection
PersonalNames{get;}
public?System.Storage.Core.EAddressCollection
PersonalEAddresses{get;}
public?System.Storage.Core.PostalAddressCollection
PersonalPostalAddresses{get;}
public?System.Data.SqlTypes.SqlBinary
PersonalPicture{get;set;}
public?System.Storage.Core.RichTextCollection
Notes{get;}
public?System.Storage.Base.CategoryRefCollection
Profession{get;}
public?System.Storage.Base.IdentityKeyCollection
DataSource{get;}
public?System.Data.SqlTypes.SqlDateTime
Expiration?Date{get;set;}
public?System.Data.SqlTypes.SqlBoolean
HasAllAddressBookData{get;set;}
public?System.Storage.Contact.EmployeeDataCollection
EmployeeOf{get;}
public?Person();
public?Person(System.Storage.Base.Folder?folder,string?name);
public?static?new?System.Storage.FindResult
FindAll(System.Storage.ItemStore?store);
public?static?new?System.Storage.FindResult
FindAll(
System.Storage.ItemStore?store,
string?filter);
public?static?new?Person
FindOne(
System.Storage.ItemStore?store,
string?filter);
public?new?event
System.Windows.Data.PropertyChangedEventHandler
PropertyChangedHandler;
public?static?new?Person
FindByID(
System.Storage.ItemStore?store,
long?item_key);
}
As another example, the detailed structure of the TelephoneNumber type that defines in the contact schema illustrates as follows with XML:
<Type?Name=″TelephoneNumber″ExtendsType=″Core.EAddress″
MajorVersion=″1″MinorVersion=″0″ExtendsVersion=″1″>
<Field?Name=″CountryCode″Type=″the?storage?platformTypes.nvarchar(50)″
Nullable=″true″MultiValued=″false″
TypeMajorVersion=″1″/>
<Field?Name=″AreaCode″Type=″the?storage?platformTypes.nvarchar(256)″
Nullable=″true″TypeMajorVersion=″1″/>
<Field?Name=″Number″Type=″the?storage?platformTypes.nvarchar(256)″
Nullable=″true″TypeMajorVersion=″1″/>
<Field?Name=″Extension″Type=″the?storage?platformTypes.nvarchar(256)″
Nullable=″true″TypeMajorVersion=″1″/>
<Field?Name=″PIN″Type=″the?storage?platformTypes.nvarchar(50)″
Nullable=″true″TypeMajorVersion=″1″/>
</Type>
The type causes with lower class (only showing publicly-owned member):
partial?public?class?TelephoneNumber:
System.Storage.Core.EAddress,
System.Windows.Data.IDataUnit
{
public?System.Data.SqlTypes.SqlString?CountryCode
{get;set;}
public?System.Data.SqlTypes.SqlString?AreaCode
{get;set;}
public?System.Data.SqlTypes.SqlString?Number
{get;set;}
public?System.Data.SqlTypes.SqlString?Extension
{get;set;}
public?System.Data.SqlTypes.SqlString?PIN
{get;set;}
The hierarchy of the class that obtains from given pattern has directly reflected the hierarchy this pattern.As an example, consider the Item type (seeing Figure 21 A and 21B) that defines in the contact schema.Class hierarchy corresponding to the type in storage platform API is as follows:
Object
DataClass
ElementBase
RootItemBase
Item
Principal
Group
Household
Organization
Person
User
Service
PresenceService
ContactService
ADService
RootNestedBase
... (element class)
Another pattern promptly allows the pattern of all audio/video medias (audio file of disconnection, audio frequency CD, DVD, home videos etc.) in the expression system to make user/application program can store, organize, search for and handle different types of audio/video media.Basic media document pattern is enough generally representing any medium, and the expansion of this basic model is configured to audio and video medium separate processes territory special attribute.This pattern and many other patterns are contemplated to be directly or indirectly operates under core schema.
5. framework when moving
Basic storage platform API programming model is an object persistency.Application program is carried out search in storage, and in storage the object of key registration certificate.The object of application modification retrieval or create new object makes its change be transmitted to storage then.This process is managed by ItemContext (project context) object.Search uses ItemSearcher (project search device) object to carry out, and Search Results can visit by FindResult (searching result) object.
Framework class when a) moving
According to another invention aspect of the present invention, framework realizes that a plurality of classes support the operation of data class during operation.These framework classes are that data class has defined one group of public behavior, and provide basic programming model together with data class for storage platform API.Class during operation in the framework belongs to the System.Storage name space.In the present embodiment, the framework class comprises following main class: ItemContext, ItemSearcher and FindResult.Other less important class, enumerated value and representative also can be provided.
(1)ItemContext
ItemContext object (i) expression application program is wished one group of item domains of searching for, (ii) safeguard the status information of expression state of data retrieved from storage platform for each object, and (iii) management when with storage platform when mutual the affairs of use and can with any file system of storage platform interoperability.
As the object persistency engine, ItemContext provides following service:
1. the data that will read from storage are played a reversed role to go and are changed into object.
2. service object identity (same target is used to represent given project, and no matter this project is included in how many times in the Query Result).
3. tracing object state.
ItemContext also carries out a plurality of services unique to storage platform:
1. generate and carry out lasting the preservation and change the more new element operation of required storage platform.
2. create the seamless navigation and the permission retrieval from the multiple domain search that allow adduction relationship and will revise being connected to a plurality of data storage required with the object of preserving.
3. guarantee when the change of object indicates to preserve this project, to support that the project of file is correctly upgraded.
4. the affairs that a plurality of storage platforms connect are striden in management, and the file system that management is handled in the affairs mode when renewal is stored in data in the project of supporting file and document flow attribute.
5. carry out establishment that the attribute of the storage platform relation is semantic, as to support file project and stream typeization takes into account, duplicate, move and deletion action.
Appendix A provides the source code of listing the ItemContext class according to an one embodiment.
(2)ItemSearcher
The support of ItemSearcher class is simply searched for, and this search is returned the stream of entire I tem object, Item object or from the stream of the value of Item object projection.ItemSearcher has encapsulated following all public Core Features: the parameterized filtrator of answering the notion of target type and being applied to this target type.ItemSearcher also allows precompile or prepares searcher, as the optimization when carrying out same operation with polytype.Appendix B provides the source code of listing ItemSearcher class and some classes that are closely related according to an one embodiment.
(a) target type
The ferret out type is provided with when structure ItemSearcher.Target type is that be mapped to can be by the CLR type of the scope of data storage inquiry.Particularly, it is to be mapped to project, relation and to concern expansion type and the CLR type of medelling view.
When using ItemContext.GetSearcher method search device, the target type of searcher is designated as parameter.(for example, in the time of Person.GetSearcher), target type is project, relation or project expansion type when call static GetSeacher method on project, relation or project expansion type.
The search expression formula that provides among the ItemSearcher (for example, Search Filter and by query manipulation, or projection definition) is always with respect to the ferret out type.But the attribute of these expression formula intended target types (attribute that comprises nested element), and can be assigned to connection as the expansion of the described relation in other places and project.
The ferret out type can be passed through read only attribute (for example, Item.Searcher.Type attribute) and obtain.
(b) filtrator
ItemSearcher comprises the attribute (for example, the attribute of by name " Filters " is as the set of SearchExpression object) of given filter device, this filter definition the filtrator that uses in the search.All filtrators in the set use disjunction operation to accord with when carrying out search and make up.Filtrator can comprise parameter and quote.Parameter value comes appointment by the Parameters attribute.
(c) prepare search
May only repeat under the situation of same search, can or prepare search and improve some performance by precompile with a parameter change.This is that (for example, the method for the Find (searching) of one or more projects is returned in preparation, may be called " PrepareFind " with one group of preparation method on the ItemSearcher; And the method for preparing to return the Find of projection, may be called " PrepareProject ") realize.For example:
ItemSearcher?searcher=...;
PreparedFind?pf=searcher.PrepareFind();
...
result=pf.FindAll();
...
result=pf.FindAll();
(d) search option
There are a plurality of options that can be applicable to simple search.These can specify and be passed to the Find method in for example FindOptions (searching option) object.For example:
ItemSearcher?searcher=Person.GetSearcher(context);
FindOptions?options=new?FindOptions();
options.MaxResults=10;
options.SortOptions.Add(“PersonalNames.Surname”,SortOrder.Ascending);
FindResult?result=searcher.FindAll(options);
As a kind of facility, also sort options can be directly passed to the Find method:
ItemSearcher?searcher=Person.GetSearcher(context);
FindResult?result=searcher.FindAll(
new?SortOption(“PersonalNames.Surname”,SortOrder.Ascending));
Whether DelayLoad (delay load) option determines whether to load as a result the time when search the value of big binary attribute, perhaps loading is deferred to after they are cited.MaxResults (maximum result) option has been determined the result's that returns maximum quantity.This is equivalent to and specifies TOP in SQL query.It uses in conjunction with ordering usually.
The sequence of SortOption (sort options) object can be designated (for example, using the FindOptions.SortOptions attribute).Search Results will sort as specified by first SortOption object, and then as by second ordering that the SortOption object is specified, the rest may be inferred.SortOption has specified the search expression formula of indicating the attribute that will be used to sort.One of below expression formula has been specified:
1. the scalar attribute in the ferret out type;
2. can be by the scalar attribute of traversal single-value attribute from the nested element that the ferret out type arrives; Perhaps
3. the result's (for example, Max is applied to pass through traversal multi-valued attribute or the scalar attribute of relation from the nested element that the ferret out type arrives) who has the set function of effective independent variable.
For example, suppose that the ferret out type is System.Storage.Contact.Person:
1. " Birthdate "-effectively, Birthdate is the scalar attribute of Person type;
2. " PersonalNames.Surname "-invalid, PersonalNames is a multi-valued attribute, and does not use any set function;
3. " Count (PersonalNames) "-effectively, the counting of PersonalNames;
4. " Case (Contact.MemberOfHousehold) .Household.HouseholdEAddresses.StartDate "-invalid, use relation and multi-valued attribute, and do not had set function.
5. " Max (Cast (Contact.MemberOfHousehold) .Household.HouseholdEAddresses.StartDate) "-effectively, nearest household electronic address from date.
(3) project result stream (" FindResult ")
ItemSearcher (for example, by the FindAll method) returns the object (for example, " FindResult " object) that can be used for visiting the object that is returned by search.Appendix C provides the source code of listing FindResult class and some classes that are closely related according to an one embodiment.
There are two kinds of diverse ways that are used for obtaining the result from the FindResult object: use reader mode by IObjectReader (object reader interface) (and IAsyncObjectReader (asynchronous object reader interface)) definition, and the enumerator pattern that uses IEnumerable (can enumerate interface) and IEnumerator (enumerator interface) definition.Enumerator pattern is the standard among the CLR, and supports the language construct such as foreach as C#.For example:
ItemSearcher?searcher=Person.GetSearcher(context);
searcher.Filters.Add(“PersonalNames.Surname=‘Smith’”);
FindResult?result=searcher.FindAll();
foreach(Person?personin?result)...;
Support reader mode, because it allows to come more effectively result by eliminating data trnascription in some cases.For example:
ItemSearcher?searcher=Person.GetSearcher(context);
searcher.Filters.Add(“PersonalNames.SurName=‘Smith’”);
FindResult?result=searcher.FindAll();
while(result.Read())
{
Person?person=(Person)result.Current;
...
}
In addition, reader mode is supported asynchronous operation:
ItemSearcher?searcher=Person.GetSearcher(context);
searcher.Filters.Add(“PersonalNames.SurName=‘Smith’”);
FindResult?result=searcher.FindAll();
IAysncResult?asyncResult=result.BeginRead(new?AsyncCallback(MyCallback));
void?MyCallback(IAsyncResult?asyncResult)
{
if(result.EndRead(asyncResult))
{
Person?person=(Person)result.Current;
...
}
}
In the present embodiment, FindResult should be closed when it no longer needs.This can be by calling Close (closing) method or using and finish such as language construct such as the employed statements of C#.For example:
ItemSearcher?searcher=Person.GetSearcher(context);
searcher.Filters.Add(“PersonalNames.SurName=‘Smith’”);
using(FindResult?result=searcher.FindAll())
{
while(result.Read())
{
Person?person=(Person)result.Current;
...
}
}
B) operation in operation the time framework
Framework when Figure 22 shows operation in the operation.The following operation of framework during this operation:
1. application program 350a, 350b or 350c are tied to the project in the storage platform.
2. framework 2004 is created ItemContext (project context) object 2202 corresponding to the project of binding, and it is returned to application program.
3. application program submits to Find to obtain project set on this ItemContext; Returned to be integrated into conceptive be object diagram 2204 (because relation).
4. application program changes, deletes and the insertion data.
5. application program is preserved change by calling Update () method.
C) public programming mode
This section provides storage platform API framework class how to can be used in the various examples of the project in the manipulation data storage.
(1) opens and closes the ItemContext object
Application program for example will be used for the ItemContext object mutual with data storage by calling static ItemContext.Open method and providing one or more paths of the item domains that sign will be associated with ItemContext to obtain it.Item domains is used the scope of the performed search of ItemContext surely, makes that only the territory project will be searched for the project that is included in this project.Example is as follows:
Open and on local computer, have the ItemContext that the DefaultStore storage platform is shared
ItemContext?ic=ItemContext.Open()
Open and have the ItemContext that given storage platform is shared
ItemContext?ic=ItemContext.Open(@″\\myserver1\DefaultStore″);
Open ItemContext with the project under storage platform is shared
ItemContext?ic=ItemContext.Open(@″\\myserver1\WinFSSpecs\api\m6″);
Open ItemContext with a plurality of item domains
ItemContext?ic=ItemContext.Open(@″\\myserver1\My?Documents″.
@″\\jane1\My?Documents″,
@″\\jane2\My?Documents″);
When no longer needing ItemContext, it must be closed.
Explicitly is closed ItemContext
ItemContext?ic=ItemContext.Open();
...
ic.Close();
Use has the statement of ItemContext and closes
using(ItemContext?ic=ItemContext.Open())
{
...;
}
(2) object search
According to another aspect of the present invention, storage platform API provides and has made that the application programmer can be based on the various attributes of the project in the data storage, forms the interrogation model of the simplification of inquiry in the mode that the details of the query language of application programmer and underlying database engine is isolated.
Application program can be carried out search in the territory of appointment when using the ItemSearcher object that is returned by the ItemContext.GetSearcher method to open ItemContext.Search Results uses the FindResult object to visit.Suppose following statement to following example:
ItemContextic=...;
ItemSearcher?searcher=null;
FindResult?result=null;
Item?item=null;
Relationship?relationship=null;
ItemExtension?itemExtension=null;
The basic search pattern relates to use by calling the ItemSearcher object that GetSearcher (acquisition searcher) method retrieves from ItemContext.
Search for all items of given type
searcher=ic.GetSearcher(typeof(Person));
result=searcher.FindAll();
Foreach (the Person p among the result) ...;
The project of the given type of filtrator is satisfied in search
searcher=ic.GetSearcher(typeof(Person));
searcher.Filters.Add(″PersonalNames.Surname=′Smith′″);
result=searcher.FindAll();
Foreach (the Person p among the result) ...;
Use the parameter in the filtrator string
searcher=ic.GetSearcher(typeof(Person));
searcher.Filters.Add(″Birthdate<@Date″);
searcher.Parameters[″Date″]=someDate;
result=searcher.FindAll();
Foreach (the Person p among the result) ...;
Search for given type and satisfy the relation of filtrator
searcher=ic.GetSearcher(typeof(EmployeeEmployer));
searcher.Filters.Add(″StartDate<=@Date?AND?(EndDate>=@Date?OR?isnull(EndDate))″);
searcher.Parameters[″Date″]=someDate;
result=searcher.FindAll();
Foreach (the EmployeeEmployer ee among the result) ...;
Search has given type and satisfies the project of the relation of filtrator
searcher=ic.GetSearcher(typeof(Folder));
Searcher.Filters.Add (" MemberRelationships.Name like ' A% ' "); // see [ApiRel]
result=searcher.FindAll();
Foreach (the Folder f among the result) ...;
Search for given type and satisfy the project expansion of filtrator
searcher=ic.GetSearcher(typeof(ShellExtension));
searcher.Filters.Add(″Keywords.Value=′Foo′″);
result=searcher.FindAll();
Foreach (the ShellExtension se among the result) ...;
Search has given type and satisfies the project of the project expansion of filtrator
searcher=ic.GetSearcher(typeof(Person));
Searcher.Filters.Add (" Extensions.Cast (@Type) .Keywords.Value=' Foo ' "); // see [ApiExt]
searcher.Parameters[″Type″]=typeof(ShellExtension);
result=searcher.FindAll();
Foreach (the Person p among the result) ...;
(a) search option
Can when carrying out search, specify variety of option, comprise ordering, postpone to load and the restriction number of results.
Rank search result
searcher=ic.GetSearcher(typeof(Person));
searcher.Filters.Add(″PersonalNames.Surname=′Smith′″);
SearchOptions?options=new?SearchOptions();
options.SortOptions.Add(new?SortOption(″Birthdate″,SortOrder.Ascending));
result=searcher.FindAll(options);
Foreach (the Person p among the result) ...;
// there is shortcut to use
searcher=ic.GetSearcher(typeof(Person));
searcher.Filters.Add(″PersonalNames.Surname=′Smith′″);
result=searcher.FindAll(new?SortOption(″Birthdate″,SortOrder.Ascending));
Foreach (the Person p among the result) ...;
The restriction result count
searcher=ic.GetSearcher(typeof(Person));
searcher.Filters.Add(″PersonalNames.Surname=′Smith′″);
SearchOptiohs?options=new?SearchOptions();
options.MaxResults=10;
result=searcher.FindAll(options);
Foreach (the Person p among the result) ...;
(b) FindOne and FindOnly
Sometimes it is useful only retrieving first result, especially when specifying ranking criteria.In addition, expect that some search only returns an object, and do not expect that it does not return any object.
Search for an object
searcher=ic.GetSearcher(typeof(Person));
searcher.Filters.Add(″PersonalNames.Surname=’Smith’″);
Person?p=searcher.FindOne(new?SortOption(″Birthdate″SortOrder.Ascending))as?Person;
if(p!=null)...;
The single object that the search expectation always exists
searcher=ic.GetSearcher(typeof(Person));
searcher.Filters.Add(″PersonalNames[Surname=’Smith’AND?Givenname’John’]″);
try
{
Person?p=searcher.FindOnly();
...;
}
catch(Exception?e)
{
...;
}
(c) shortcut on the Searching I temContext
Also have on the ItemContext and make simple search be easy to some shortcuts as far as possible.
Use the search of ItemContext.FindAll shortcut
result=ic.FindAll(typeof(Person),″PersonalNames.Surname=′Smith′″);
Foreach (the Person p among the result) ...;
Use the search of Item.Context.FindOne shortcut
Person?p=ic.FindOne(typeof(Person),″PersonalNames.Sumame=′Smith′″)as?Person;
(d) according to ID or path searching
In addition, can come search terms, relation and project expansion by its id is provided.Project also can be retrieved according to the path.
Given id obtains project, relation and project expansion
item=ic.FindltemById(iid);
relationship=ic.FindRelationshipById(iid,rid);
itemExtension=ic.FindItemExtensionById(iid,eid);
Given path obtains project
// individual domain only
item=ic.FindItemByPath(@″temp\foo.txt″);
// single or multiple territories
result=ic.FindAllItemsByPath(@″temp\foo.txt″);
Foreach (the Item I among the result) ...;
(e) GetSearcher pattern
In storage platform API, there are many expectations to be provided in the context of another object or many places of carrying out assistant's method of search with specific parameter.The GetSearcher pattern allows these situations.Many GerSearcher methods are arranged in API.Its each all return the ItemSearcher that is configured to carry out given search in advance.
For example:
searcher=itemContext.GetSearcher();
searcher=Person.GetSearcher();
searcher=EmployeeEmployer.GetSearcherGivenEmployer(organization);
searcher=person.GetSearcherForReports();
Can before carrying out search, add other filtrator:
searcher=person.GetSearcherForReports();
searcher.Filters.Add(″PersonalNames.Surname=’Smith’″);
Can select how to wish the result:
FindResult?findResult=searcher.FindAll();
Person?person=searcher.FindOne();
(3) updated stored
In case retrieved object by search, it can be by the required modification of application program.Also can create new object and be associated with existing object.In case application program has been made the institute that forms logical groups and changed, application call ItemContext.Update is saved in these changes in the storage lastingly.According to the another aspect of storage platform API of the present invention, API collects the change of project being made by application program, then they is organized into the required correct renewal of database engine (or storage engines of any kind of) that realizes data storage on it.This makes the application programmer to make a change the project in the storer, and leaves the complicacy that data storage is upgraded for API.
Preservation is to the change of single project
Person?p=ic.FindItemById(pid)as?Person;
p.DisplayName=″foo″;
p.TelephoneNumbers.Add(new?TelephoneNumber(″425-555-1234″));
ic.Update();
Preservation is to the change of a plurality of projects
Household?h1=ic.FindItemById(hid1)as?Household;
Household?h2=ic.FindItemById(hid2)as?Household;
Person?p=ic.FindItemById(pid)as?Person;
h1.MemberRelationships.Remove(p);
h2.MemberRelationships.Add(p);
ic.Update();
Create new projects
Folder?f=ic.FindltemById(fid)as?Folder;
Person?p=new?Person();
p.DisplayName=″foo″;
f.Relationships.Add(new?FolderMember(p,″foo″));
ic.Update();
// or use shortcut ...
Folder?f=ic.FindItemByld(fid)as?Folder;
Person?p=new?Person();
p.DisplayName=″foo″;
f.MemberRelationships.Add(p,″foo″);
ic.Update();
Deletion relation (and possible destination item)
searcher=ic.GetSearcher(typeof(FolderMember));
searcher.Filters.Add(″SourceItemId=@fid″);
searcher.Filters.Add(″TargetItemId=@pid″);
searcher.Parameters.Add(″fid″,fid);
searcher.Parameters.Add(″pid″,pid);
Foreach (the FolderMember fm among the searcher.FindAll ()) fm.MarkForDelete ();
ic.Update();
// or use shortcut ...
Folder?f=ic.FindItemById(fid)as?Folder;
f.MemberRelationships.Remove(pid);
ic.Update();
The expansion of interpolation project
Item?item=ic.FindItemById(iid);
MyExtension?me=new?MyExtension();
me.Foo=″bar″;
item.Extensions.Add(me);
ic.Update();
The delete items expansion
searcher=ic.GetSearcher(typeof(MyExtension));
searcher.Filters.Add(″ItemId=@iid″);
searcher.Parameters.Add(″iid″,iid);
Toreach (the MyExtension me among the searcher.FindAll ()) me.MarkForDelete ();
ic.Update();
// or use shortcut ...
Item?i=ic.FindItemById(iid);
i.Extensions.Remove(typeof(MyExtension));
ic.Update();
6. security
With reference to above II.E joint (security), in the present embodiment of storage platform API, on the project context, have five kinds of methods can be used for retrieving and revise with store in the security strategy that is associated of project.These methods are:
1.GetItemSecurity
2.SetItemSecurity;
3.GetPathSecurity;
4.SetPathSecurity; And
5.GetEffectiveItemSecurity。
GetItemSecurity and SetItemSecurity provide the mechanism of the explicit ACL that retrieval and modification be associated with project.This ACL is independent of existing path to project, and underway being independent of has the hold relation of this project as target.This makes the keeper can be independent of the security that existing path estimating to project goes out project as expected.
GetPathSecurity and SetPathSecurity provide and have been used to retrieve and revise owing to concerning the mechanism that is present in the ACL on the project from holding of another file.This ACL is made up of from each ancestors' ACL to this project and to the explicit ACL (if providing) in this path the path in considering.Difference between the ACL under this ACL and the last situation is only just underway reservation when the corresponding relation of holding exists of this ACL, and explicit project ACL is independent of any relation of holding to this project.
The ACL that can be provided with SetItemSecurity and SetPathSecurity on project is limited to hereditable and the ACE object special use.They can not comprise any ACE that is marked as succession.
GetEffectiveItemSecurity retrieves various paths based on the explicit ACL on ACL and the project.This has reflected effective delegated strategy on the given project.
7. the support to concerning
As mentioned above, the data model of storage platform has defined " relation " that the permission project is relative to each other.When the data class of generate pattern, for each relationship type produces with lower class:
1. the class of expression relation itself.Such is derived from the Relationship class, and comprises the member to the relationship type special use.
2. " virtual " collection class of strong typing.Such is derived from VirtualRelationshipCollection (virtual set of relationship), and allows to create and the deletion relationship example.
This section has been described the support to concerning among the storage platform API.
A) primary relationship type
Storage platform API provides the polytype that forms the basis that concerns API in the System.Storage name space.These types are:
The type of foundation of (1.Relationship relation)-all relation objects
The type of foundation of (2.VirtualRelationshipCollection virtual set of relationship)-all set of relationship
(3.ItemReference project is quoted), ItemIdReference (item id is quoted), ItemPathReference (item Path is quoted)-expression project reference type; Relation between these types is shown in Figure 11.
(1) Relationship class
public?abstract?class?Relationship:StoreObject
{
// create with default value
protected?Relationship(ItemIDReference?targetItemReference);
// notice concerns that it is added to set of relationship.Object will be inquired to gather and be determined source item, project context etc.
internalAddedToCollection(virtualRelationshipCollection?collection);
The ID of // relation
public?RelationshipId?RelationshipId{get;}
The ID of // source item
public?ItemId?SourceItemId{get;}
// acquisition source item
public?Item?SourceItem{get;}
// quoting to destination item
public?ItemIdReference?TargetItemReference{get;}
// acquisition destination item (calling TargetItemReference.GetItem ())
publicItem?TargetItem{get;}
// determine whether ItemContext has had to the connection in the territory of destination item
// (call TargetItemReference, IsDomainConnected)
public?bool?isTargetDomainConnected{get;}
The name of // destination item in name space.This name must close that to fasten be unique in holding of all source item
public?OptionalValue<string>Name{get;set;}
// determine that this holds or adduction relationship
public?OptionalValue<bool>IsOwned{get;set;}
}
(2) ItemReference class
It below is the base class of project reference type.
public?abstract?class?ItemReference:NestedElement
{
// create with default value
protacted?ItemReference();
// return the project of quoting
public?virtual?Item?GetItem();
// determine whether to have set up to the connection in the territory of the project of quoting
public?virtual?bool?IsDomainConnected();
}
The ItemReference object can identify be present in except that project quote itself the project in the storage the resident storage.The type of each derivation has specified how to construct and use quoting remote storage.The realization of GetItem and IsDomainConnected uses the multiple domain support of ItemContext to come loading project from required territory in the derivation class, and has determined whether to set up the connection to this territory.
(3) ItemIdReference class
Below be that the project that ItemIdReference class-use item id identifies destination item is quoted.
public?class?ItemIdReference:ItemReference
{
// construct new ItemIdReference with default value
public?ItemIdReference();
// structure is to the new ItemIdReference of technical routine.The territory that is associated with this project is as finger URL
public?ItemIdReference(Item?item);
// construct new ItemIdReference with null locator and given destination item ID
public?ItemIdReference(ItemId?itemId);
// construct new ItemIdReference with given finger URL and item id value
public?ItemIdReference(string?locator,ItemId?itemId);
The ID of // destination item
public?ItemId?ItemId{get;set;}
// be identified at the path of the WinFS project that comprises destination item in its territory.If be empty, the territory that then comprises this project is unknown.
public?OptionalValue<string>Locator{get;set;}
// determine whether to have set up to the connection in the territory of the project of being quoted
public?override?bool?IsDomainConnected();
The project that // retrieval is quoted
public?override?Item?GetItem();
}
GetItem and IsDomainConnected use the multiple domain support of ItemContext to come loading project from required territory, and have determined whether to set up the connection to this territory.This feature still is unrealized.
(4) ItemPathReference class
The project that the ItemPathReference class is to use the path to identify destination item is quoted.The code that is used for such is as follows:
public?class?ItemPathReference:ItemReference
{
// quote with default value structure item Path
public?ItemPathReference();
// need not any finger URL but quote with given path structure item Path
public?ItemPathReference(string?path);
// quote with given finger URL and path configuration item Path
public?ItemPathReference(string?locator,string?path);
// be identified at the path of the WinFS project that comprises destination item in its territory
public?OptionalValue<string>Locator{get;set;}
// with respect to destination item path by the item domains of finger URL appointment
public?string?Path{get;set;}
// determine whether to have set up to the connection in the territory of the project of being quoted
public?override?bool?IsDomainConnected();
The project that // retrieval is quoted
public?override?Item?GetItem();
}
GetItem and IsDomainConnected use the multiple domain support of ItemContext to come loading project from required territory, and have determined whether to set up the connection to this territory.
(5) RelationshipId structure
The RelationshipId construction packages relations I D GUID.
public?class?RelationshipId
{
The relations I D GUID that // generation is new
public?static?Relationshipld?NewRelationshipId();
// with new relations I D GU ID initialization
public?RelationshipId();
The GUID initialization of // usefulness appointment
public?RelationshipId(Guid?Id);
// identify initialization with the string of GUID
public?RelationshipId(string?id);
// return the string sign of relations I D GUID
public?override?string?ToString();
// convert the System.Guid example to the RelationshipId example
public?static?implicit?operator?RelationshipId(Guid?guid);
// convert the RelationshipId example to the System.Guid example
public?static?implicit?operator?Guid(RelationshipId?relationshipId);
}
This value type of package GUID, make that parameter and attribute can be relations I D by strong typing.OptionalValue<RelationshipId〉should when can be sky, use relations I D.Do not represented such as the null value that provides by System.Guid.Empty.RelationshipId can not construct with null value.When the constructed fuction that uses acquiescence is created RelationshipId, create new GUID.
(6) VirtualRelationshipCollection class
The VirtualRelationshipCollection class has realized comprising that the object from data storage adds the new object that is added to set, but does not comprise the set of the relationship object of the object that removes from storage.The object of the specified relationship type of given source item ID is included in this set.
This is the base class for the set of relationship class of each relationship type generation.Such can be used as the type of the attribute in the source item type, so that visit and the simple and easy manipulation to the relation of given project to be provided.
The content of enumerating VirtualRelationshipCollection may require to load a large amount of relationship objects from storage.Application program should use Count (counting) attribute to determine to load how many relations before enumerating the content of this set.Add object/remove object from set to set and do not need the relation that from storage, loads.
For the purpose of efficient, preferably the relation of specified criteria is satisfied in the application program search, but not uses all project relationships of VirtualRelationshipCollection object enumeration.Adding relationship object to set makes create represented relation when calling ItemContext.Update in storage.Removing relationship object from set makes to delete represented relation when call ItemContext.Update in storage.Virtual set comprises correct object set, and no matter whether add/removed relationship object by any other set of relationship on Item.Relationships set or this project.
Following code definition the VirtualRelationshipCollection class:
public?abstract?class?VirtualRelationshipCollection:ICollection
{
// this set comprises the relation by the type that project had of project itemId sign
protected?VirtualRelationshipCollection(ItemContext?itemContext,
ItemId?itemId.
Type?relationshipType);
// enumerator will return all objects that retrieve and deduct except that the object with state I nserted (inserting) from storage
// outside any object with state Deleted (deleting)
public?IEnumerator?GetEnumerator();
// return the counting of the number of the relationship object that returns by enumerator.This counting need not to retrieve all objects and can calculate from storage.
public?int?Count{get;}
// always return vacation
public?bool?lcollection.IsSynchronized(){get;}
// always return this object
public?object?ICollection.SyncRoot{get;}
Required object in the // search storage
public?void?Refresh();
// to gathering the relation of adding appointment.Object must have state Constructed (constructing) or Removed (removing).
If // state is Constructed, it is changed to Added (adding).If state is Removed, then it is suitably
// change Retrieved (retrieving) or Modified (revising) into.The source item ID of relation must be with when the construction set
// source item the ID that provides is identical.
protected?void?Add(Relationship?relationship);
// from set, remove the relation of appointment.The state of object must be Added, Ret rieved or Modified.
If // Obj State is Added, it will be set as Constructed.If Obj State is Retrieved or Modifieed,
// it will be set as Removed.The source item ID of relation must be identical with the source item ID that provides when the construction set.
protected?void?Remove(Relationship?relationship);
// the object that removes from set
public?ICollection?RemovedRelationships{get;}
// be added to the object of set
public?ICollection?AddedRelationshipas{get;}
The object of // retrieval from storage.This set will be sky, up to having enumerated VirtualRelationshipCollection
// or called (value that obtains this attribute does not cause filling up this set) after the Refresh.
public?ICollection?StoredRelationships{get;}
// anonymous methods
public?IAsyncResult?BeginGetCount(IAsyncCallback?callback,object?state);
public?int?EndGetCount(IAsyncResult?asyncResult);
public?IAsyncResult?BeginRefresh(IAsyncCallback?callback,object?state);
public?void?EndRefresh(IAsyncResult?asyncResult);
}
B) relationship type of Sheng Chenging
When for the storage platform pattern generates time-like, be class of each relation statement generation.Except that the class of expression relation itself, also generate the set of relationship class for each relation.These classes are as the source of relation or the attribute type in the destination item class.
This section has been described the class of using some " prototype " class to generate.That is, the class that generates has been described in the statement of the relation of given appointment.Be important to note that the class of using in the prototype class, type and end points name are the placeholders of the name of appointment in the relation schema, and be not taken on the literal and explain.
(1) relationship type of Sheng Chenging
This section has been described the class that generates for each relationship type.For example:
<Relationship?Name=″RelationshipPrototype″BaseType=″Holding″>
<Source?Name=″Head″ItemType=″Foo″/>
<Target?Name=″Tail″ItemType=″Bar″ReferenceType=″ItemIDReference″/>
<Property?Name=″SomeProperty″Type=″WinFSTypes.String″/>
</Relationship>
Given this contextual definition RelationshipPrototype (concerning prototype) will generate RelationshipPrototypeCollection (concerning the prototype set) class.The RelationshipPrototype class is represented relation itself.The RelationshipPrototypeCollection class provides the visit as the RelationshipPrototype example of source endpoint of project with appointment.
(2) RelationshipPrototype class
This is the prototype relation object that is used to be called the relation of holding of " HoldingRelationshipPrototype (hold and concern prototype) ", wherein source endpoint is called " Head ", and specified " Foo " item types, and target endpoint " Tail " by name, and specified " Bar " item types.It is defined as follows:
public?class?RelationshipPrototype:Relationship
{
public?RelationshipPrototype(Bar?tailItem);
public?RelationshipPrototype(Bar?tailItem,string?name);
public?RelationshipPrototype(Bar?tailItem,string?name,bool?IsOwned);
public?RelationshipPrototype(Bar?tailItem,bool?IsOwned);
public?RelationshipPrototype(ItemIdReference?tailItemReference);
// acquisition Head project (calling base.SourceItem)
public?Foo?HeadItem{get;}
// acquisition Tail project (calling base.TargetItem)
public?Bar?TailItem{get;}
Other attribute of stating in // expression the relation schema.These are to generate the attribute in project or nested element type.
public?string?SomeProperty{get;set;}
public?static?ItemSearcher?GetSearcher(ItemContext?itemContext);
public?static?ItemSearcher?GetSearcher(Foo?headItem);
public?static?FindResult?FindAll(string?filter);
public?static?RelationshipPrototype?FindOne(string?filter);
public?static?RelationshipPrototype?FindOnly(string?filter);
}
(3) RelationshipPrototpyeCollection class
This is the prototype class that generates with the RelationshipPrototype class, and its safeguards the set of the RelationshipPrototype relationship example that the project by appointment has.It is defined as follows:
public?class?RelationshipPrototypeCollection:VirtualRelationshipCollection
{
public?RelationshipPrototypeCollection(ItemContext?itemContext,
ItemId?headItemId);
public?void?Add(RelationshipPrototype?relationship);
public?RelationshipPrototype?Add(Bar?bar);
public?RelationshipPrototype?Add(Bar?bar,string?name);
public?RelationshipPrototype?Add(Bar?bar,string?name,bool?IsOwned);
public?RelationshipPrototype?Add(Bar?bar,bool?IsOwned);
public?void?Remove(RelationshipPrototype?relationship);
public?void?Remove(Bar?bar);
public?void?Remove(ItemId?barItemId);
public?void?Remove(RelationshipId?relationshipId);
public?void?Remove(string?name);
}
C) concern support in the Item class
The Item class comprises that to provide this project wherein be the Relationships attribute of visit of relation in the source of relation.The Relationships attribute has type RelationshipCollection.
(1) Item class
Following code shows the context property that concerns of Item class:
public?abstract?class?Item:StoreObject
{
...
// wherein this project is the set of the relation in source
public?RelationshipCollection?Relationships{get;}
...
}
(2) RelationshipCollection class
Such provides given project wherein is the visit of relationship example in the source of relation.It is defined as follows:
public?class?RelationshipCollection:VirtualRelationshipCollection
{
public?RelationshipCollection(ItemContext?itemContext,
ItemId?headItemId);
public?void?Add(Relationship?relationship);
public?Relationship?Add(Bar?bar);
public?Relationship?Add(Bar?bar,string?name);
public?Relationship?Add(Bar?bar,string?name,bool?IsOwned);
public?Relationship?Add(Bar?bar,bool?IsOwned);
public?void?Remove(Relationship?relationship);
public?void?Remove(Bar?bar);
public?void?Remove(ItemId?barItemId);
public?void?Remove(RelationshipId?relationshipId);
public?void?Remove(string?name);
}
D) concern support in the search expression formula
May be in the search expression formula the traversal of connection between specified relationship and the relevant item.
(1) traverses relation from project
When the current context of search expression formula is one group of project, project and wherein this project be that connection between the relationship example in source can use the Item.Relationships attribute to finish.The relation that is attached to particular type can use the Cast of search expression formula (coercion of type conversion) operational symbol to specify.
The set of relationship of strong typing (for example, Folder.MemberRelationships) also can be used in the search expression formula.Coercion of type conversion to relationship type is an implicit expression.
In case set up this group relation, the attribute of this relation can be used for judging or as the target of projection.When being used to specify the target of projection, will return this group relation.For example, the following statement StartDate attribute that will find out the relation of relating to wherein has more than or equal to everyone of the tissue of the value of " 1/1/2000 ".
FindResult?result=Person.FindAll(context,
″Relationships.Cast(Contact.EmployeeOfOrganization).StartDate>’1/1/2000’″);
If the Person type has the attribute EmployerContext that type is EmployeeSideEmployerEmployeeRelationships (the EmployeeEmployer relationship type is generated), then this will be written as:
FindResult?result=Person.FindAll(context,
″EmployerRelationships.StartDate>’1/1/2000’″);
(2) traverse project from relation
When the current context of search expression formula is one group when concerning, can calls the roll by designated ends and travel through connection from the arbitrary end points that is related to relation.In case set up this group relevant item, the attribute of those projects can be used for judging or as the target of projection.When being used to specify the target of projection, will return this group project.For example, all EmployeeOfOrganization (employee of tissue) relation that employee's surname wherein is a name " Smith " (no matter and what tissue is) will be found out in following statement:
FindResult?result=EmployeeOfOrganization.FindAll(context,
“Employee.PersonalNames[SurName=’Smith′]”);
Search expression formula Cast operational symbol can be used for filtering the type of end points project.For example, the member is all MemberOfFoler (file member) relationship example with Person project of surname " Smith " in order to find out wherein:
FindResult?result=MemberOfFolder.FindAll(context,
“Member.Cast(Contact.Person).PersonalNames[Surname=’Smith’]”);
(3) syntagmatic traversal
Preceding two kinds of patterns promptly can be combined to realize complicated arbitrarily traversal from the project relation of traversing and from the relation project of traversing.For example, for find out have surname for the employee's of " Smith " institute in a organized way:
FindResult?result=Organization.FindAll(context,
“EmployeeRelationships.”+
“Employee.”+
“PersonalNames[SurName=‘Smith’]”);
Following example will be found out all Person projects (planning item: this no longer supports ... it is a kind of replacement) that the people of " New York " regional family is lived in expression.
FindResult?result=Person.FindAll(context,
“Relationships.Cast(Contact.MemberOfHousehold).”+
“Household.”+
“Relationships.Cast(Contact.LocationOfHousehold).”+
“MetropolitonRegion=‘New?York’“);
E) example of relation support is used
Below be how to use the support that concerns among the storage platform API to handle the example of relation.For following example, suppose following statement:
ItemContext?ic=...;
Itemld fid=...; // portfolio item purpose ID
Folder?folder=Folder.FindById(ic,fid);
Itemld sid=...; The ID of // source item
Item?source=Item.FindById(ic,sid);
Itemld tid=...; The ID of // destination item
Item?target=Item.FindById(ic,tid);
ItemSearcher?searcher=null;
(1) search relation
Possible search source or relationship by objective (RBO).Can use filtrator to select specified type and have the relation of given attribute value.Also can use filtrator to select based on the relevant item type or the property value that concern.For example, can carry out following search:
All relations that wherein given project is the source
searcher=Relationship.GetSearcher(folder);
Foreach (the Relationship relationship among the searcher.FindAll ()) ...;
Wherein given project is all relations in source with name of coupling " A% "
searcher=Relationship.GetSearcher(folder);
searcher.Filters.Add(″Name?like′A%′″);
Foreach (the Relationship relationship among the searcher.FindAll ()) ...;
All FolderMember relations that wherein given project is the source
searcher=FolderMember.GetSearcher(folder);
Foreach (the FolderMember folderMember among the searcher.FindAll ()) ...;
Wherein given project is all FolderMember relations of source and name as " A% "
searcher=FolderMember.GetSearcher(folder);
searcher.Filters.Add(″Name?like′A%′″);
Foreach (the FolderMember folderMember among the searcher.FindAll ()) ...;
Wherein destination item is all FolderMember relations of Person
searcher=FolderMember.GetSearcher(folder);
searcher.Filters.Add(″Memberltem.Cast(Person)″);
Foreach (the FolderMember folderMember among the searcher.FindAll ()) ...;
Wherein destination item is that surname is all FolderMember relations of the Person of " Smith "
searcher=FolderMember.GetSearcher(folder);
searcher.Filters.Add(″Memberltem.Cast(Person).PersonalNames.Surname=′Smith′″);
Foreach (the FolderMember folderMember among the searcher.FindAll ()) ...;
Except that more than the GerSearcher API that illustrates, each relation object is supported static FindAll, FineOne and FindOnly API.In addition, relationship type can be specified when calling ItemContext.GetSearcher, ItemContext.FindAll, ItemContext.FindOne or ItemContext.FindOnly.
(2) navigate to the source and target project from relation
In case retrieved relationship object by search, may " navigation " arrive target or source item.The fundamental relation class provides SourceItem (source item) and TargetItem (destination item) attribute that returns the Item object.The relation object that is generated provides the attribute (for example, FolderMember.FolderItem and FolderMember.MemberItem) of equivalent strong typing and name.For example:
Navigate to the source and target project of the relation of " Foo " by name
searcher=Relationship.GetSearcher();
searcher.Filters.Add(″Name=′Foo′″);
Foreach (the Relationship relationship among the searcher.FindAll ())
{
Item?source=relationship.Sourceltem;
Item?target=relationship.TargetItem;
}
Navigate to destination item
searcher=FolderMember.GetSearcher(folder);
searcher.Filters.Add(″Name?like′A%′″);
Foreach (the FolderMember folderMember among the searcher.FindAll ())
{
Item?member=folderMember.TargetItem;
...
}
Even navigating to destination item can not operate in destination item does not find the territory of relation therein yet.In this case, storage platform API is opened to the connection of required aiming field.Application program can need determine whether before the searched targets project to connect.
Check the destination item in the territory that does not connect
searcher=Relationsmp.GetSearcner(source);
Foreach (the Relationship relationship among the searcher.FindAll ())
{
if(relationship.IsTargetDomaiinConnected)
{
Item?member=relationship.TargetItem;
...
}
}
(3) navigate to relation from source item
Given item objects may navigate to the relation of this project for its source, and need not to carry out explicit search.This can use the Item.Relationships aggregate attribute or finish such as the aggregate attribute of strong typings such as Folder.MemberRelationships.From relation, may navigate to destination item.Even this navigation destination item not with item domains that the ItemContext of source item is associated in the time also can operate, comprise when destination item is not in the storage identical with source item.For example:
Navigate to relation again to destination item from source item
Console.WriteLine(″Item{0}is?the?source?of?the?following?relationships:″,source.Itemld);
Foreach (the Relationship relationship among the source.Relationships)
{
Item?target=relationship.TargetItem;
Console.WriteLine(″{0}==>{1}″,relationship.Relationshipld,target.ItemId);
}
Navigate to the file member relation again to destination item from the file project
console.WriteLine(″Item{0}is?the?source?of?the?following?relationships:″,tolder.ItemId);
Foreach (the FolderMember folderMember among the folder.MemberRelationships)
{
Item?target=folderMember.GetMemberItem();
Console.WriteLine(″{0}==>{1}″,folderMember.Relationshipld,target.ItemId);
Project can have many relations, so application program should careful use when enumerating set of relationship.Generally speaking, should use search to identify interested particular kind of relationship but not enumerate whole set.Yet, relation is had programming model and enough valuable based on set, and it is few as to suffice to show that the risk that the developer abuses to have the project of many relations.Application program can be checked the number of the relation in the set, and uses different programming models when needed.For example:
Check the size of set of relationship
if(folder.MemberRelationships.Count>1000)
{
Console.WriteLine(″Too?many?relationships!″);
}
else
{
...
}
It is " virtual " that above-mentioned relation is integrated on the meaning that in fact they need not represent that the object of each relation fills, and removes nonusable routine and attempts to enumerate this set.If this set is enumerated, then the result has reflected in the storage what is arranged, and adds that application program adds but what has not been preserved, but does not reflect by application program and remove but any relation of not preserving.
(4) create relation (and project)
New relation by create relationship object, with its add to set of relationship in the source item, and more new projects' context create.For creating new projects, must create and hold or the relation of embedding.For example:
Add new projects to the existing file folder
Bar?bar=new?Bar();
folder.Relationships.Add(new?FolderMember(bar,″name″));
ic.Update();
// or
Bar?bar=new?Bar();
folder.MemberRelationships.Add(new?FolderMember(bar,″name″));
ic.Update();
// or
Bar?bar=new?Bar();
folder.MemberRelationships.Add(bar,name);
ic.Update();
Add off-the-shelf item to the existing file folder
folder.MemberRelationships.Add(target,″name″);
ic.Update();
Add off-the-shelf item to new folder
Folder?existingFolder=ic.FindltemById(fid)as?Folder;
Folder?newFolder=new?Folder();
existingFolder.MemberRelationships.Add(newFolder,″a?name″);
newFolder.MemberRelationships.Add(target,″a?name″);
ic.Update();
Add new projects to new folder
Folder?existingFolder=ic.FindltemById(fid)as?Folder;
Folder?newFolder=new?Folder();
existingFolder.MemberRelationships.Add(newFolder,″a?name″);
Bar?bar=new?Bar();
newFolder.MemberRelationships.Add(ba?r,″a?name″);
ic.Update();
(5) deletion relation (and project)
Relation is held in deletion
If // source item and relations I D are known ...
RelationshipId?rid=...;
Relationship?r=ic.FindRelationshipById(fid,rid);
r.MarkForDelete;
ic.Update();
// otherwise ...
folder.MemberRelationships.Remove(target);
ic.Update();
8. " expansion " storage platform API
As mentioned above, each storage platform pattern all causes a category.These classes have such as standard methods such as Find*, and also have the attribute that is used to be provided with and obtain field value.These classes and the method that is associated have formed the basis of storage platform API.
A) territory behavior
Except that these standard methods, each pattern has one group of territory special method that is used for this pattern.These methods are become the territory behavior.For example, some territory behavior is in the contact schema:
Whether e-mail address effective?
Given file obtains all members' of this document folder set.
Given item id, the object of this project of acquisition expression.
Given people obtains its presence.
Assistant Function is created new contact person or interim contact person.
Or the like.
Be important to note that although made difference between " standard " behavior (Find* etc.) and territory behavior, they only show as method to the programmer.Instrument generated automatically from schema file when the difference between these methods was that criterion behavior is designed by storage platform API, and the territory behavior is a hard coded.
With regard to its person's character, the territory behavior should be a home built.This causes the initial version of practical problems a: C# to require the whole of class to be implemented in the single file.Thus, this forces the class file of automatic generation to be edited to add the territory behavior.This itself is exactly a problem.
In C#, introduce a kind of feature that is called local class for suchlike problem.The most basically, local class allows class to realize crossing over a plurality of files.Local class is identical with conventional class, and difference is that key word partial is arranged before it is stated:
partial?public?class?Person:DerivedltemBase
{
// realize
}
Now, the territory behavior of Person can be placed in the different files, as:
partial?public?class?Person
{
public?EmailAddress?PrimaryEmailAddress
{
Get{/* realization */}
}
}
B) increment behavior
Data class with territory behavior has formed the basis that application developer makes up thereon.Yet it is impossible also be undesirable that data class represents each behavior that can expect relevant with these data.Storage platform allows the developer to make up on the basic function that is provided by storage platform API.Basic schema herein is to write one or more classes as parameter that its method adopts the storage platform data class.For example, be used to use Microsoft Outlook or use Microsoft Windows Messenger to come the increment class of send Email can be as follows:
MailMessage?m=MailMessage.FindOne(...);
OutlookEMailServices.SendMessage(m);
Person?p=Person.FindOne(...);
WindowsMessagerServices?m=new?WindowsMessagerServices(p);
m.MessageReceived+=new?MessageReceivedHandler(f);
m.SendMessage(″Hello″);
These increment classes can be registered to storage platform.Log-on data is associated with the pattern metadata that storage platform is safeguarded for the storage platform type of each installation.This metadata stores as storage platform items, and can be inquired about.
The registration of increment class is a kind of powerful feature; For example, it allows following situation: click by right key on the Person object in the Shell explorer, and can be from moving to deriving this group that allows the increment class of Person registration.
C) as ISP's increment behavior
In the present embodiment, storage platform API provides a kind of mechanism, and the class of wherein rising in value can be registered " service " into given type.This makes application program can be provided with and obtain the ISP of given type (=increment class).Wish to utilize the increment class of this mechanism should realize a kind of known interface; For example:
interface?IChatServices
{
void?SendMessage(string?msg);
event?MessageReceivedHandler?MessageReceived;
}
class?WindowsMessengerServices:IChatServices
{
...
}
class?YahooMessengerServices:IChatServices
{
...
}
All storage platform API data class are realized ICachedServiceProvider (ISP of high-speed cache) interface.This interface has been expanded the System.IServiceProvider interface, and is as follows:
interface?ICachedServiceProvider:System.IServiceProvider
{
void?SetService(System.Type?type,Object?provider);
void?RemoteService(System.Type?type);
}
Use this interface, application program can be provided with the ISP of ISP's example and request particular type.
For supporting this interface, the storage platform data class is safeguarded with the hash table of type as the ISP of key.When the request ISP, realize at first in hash table, checking the ISP who whether is provided with specified type.If not, then use ISP's foundation structure of registering to identify the ISP of specified type.Create this supplier's example then, add it to hash table, and return.Note, also may be by the shared method request ISP on the data class, and operation is forwarded to this supplier.For example, this can be used for providing use by the Send method on the email message class of the e-mail system of user's appointment.
9. framework when designing
This section has been described according to present embodiment of the present invention, and how the storage platform pattern converts storage platform API on the client computer and the UDT class on the server to.Figure 24 illustrates related assembly.
With reference to Figure 24, the type in the pattern is included in the XML file (frame 1).This document also comprises field level and the project level constraint that is associated with pattern.Storage platform class maker (xfs2cs.exe-frame 2) adopts this document, and generates the local class (frame 5) of storage UDT and the local class (frame 3) of client class.For each mode field, there is other method-be called territory behavior.Exist in storage (frame 7), client computer (frame 6) and (frame 4) significant territory behavior among both.Code in the frame 4,6 and 7 is hand-written (not being to generate automatically).The complete class that local class in the frame 3,4 and 6 has formed storage platform API territory class jointly realizes.Frame 3,4 and 6 by compiling (frame 8) to form storage platform API class-frame 11 (in fact, storage platform API is compiling from the frame 3,4 of all originate mode territory gained and 6 result).Except that the class of territory, also there is other class that realizes the increment behavior.These classes are utilized the one or more classes in one or more mode field.This is by frame 10 expressions.The complete class that local class in the frame 4,5 and 7 has formed server UDT class jointly realizes.Frame 4,5 and 7 by compiling (frame 9) with UDT procedure set-frame 12 of forming server side (in fact, the UDT program level of server side is that compiler adds compiling from the frame 4,5 of all originate mode territory gained and 7 result).DDL order maker module (frame 13) adopts this UDT procedure set (frame 12) and schema file (frame 1), and they are installed on the data storage.This process relates to checking of the generation of table and the type in each pattern or the like.
10. inquiry form
When being simplified the basis, the pattern of application program is when using storage platform API: open ItemContext; Use Find to retrieve desired object with filter criteria; On object, operate; And change sent it back storage.This section relates to the sentence structure what enters the filtrator string for.
The filtrator string descriptor that when searching the storage platform data object, provides the attribute of object must satisfy constraint to be returned.Support coercion of type conversion and relation traversal by the sentence structure that storage platform API uses.
A) filtrator basis
Filtrator string or be empty, indication will be returned all objects of specified type; It is the Boolean expression that each object that returns must satisfy.The attribute of expression formula reference object.Storage platform API Runtime Library knows how these attribute-name are mapped to storage platform type field name, and finally is mapped to the SQL view by the storage platform storage system maintenance.
Consider following example:
// find out everyone
FindResult?res1=Person.FindAll(ctx)
// find out its Gender (sex) property value and equal everyone of " Male " (man)
FindResult?res2=Person.FindAll(ctx,″Gender=′Male′″)
// find out that its Gender property value equals " Male " and the people of the last century birth
FindResult?res3=Person.FindAll(
ctx,
″Gender=′Male′And?Birthdate<′1/1/2001″″)
The attribute of nested object also can use in filtrator.For example:
// find out in last 24 hours everyone that revise
FindResult?res1=Person.FindAll(
ctx,
String.Format(″Item.Modified>′{0}′″,DateTime.NowSubstract(nes?TimeSpan(24,0,0))));
For set, the condition in possible user's bracket is filtered the member.For example:
// find out " John " by name and surname and be everyone of " Smith "
FindResult?res1=Person.FindAll(
ctx.
″PersonalNames[GivenName=′John′And?Surname=′Smith′]″)
// find out the real-time address and be everyone of " y " from supplier " x " and presence classification
FindResult?res2=Person.FindAll(
ctx.
″PersonalRealtimeAddress[ProviderURI=′x′].BasicPresence″+
″OnlineStatus.Category=′y′″)
Following example has been listed since 12/31/1999 everyone of birth:
ItemContext?ctx=ItemContext.Open(″Work?Contacts″);
FindResult?results=
Person.FindAll(ctx,″Birthdate>′12/31/1999′″);
Foreach (the Person person among the results)
Console.WriteLine(person.DisplayName);
ctx.Close();
The 1st row has been created new ItemContext object and has been visited " Work Contacts (the working relation people) " that storage platform on the local computer is shared.The 3rd row and the 4th row obtain the satisfied set that is later than the Person object on date of 12/31/1999 of Birthdate (birthday) attribute wherein, as specified by expression formula " Birthdate〉' 12/31/1999 ' ".The execution of this FindAll operation is shown in Figure 23.
B) coercion of type conversion
The type that situation normally is stored in the value in the attribute is the type derivation of dependency statement.For example, the PersonalEAddress among the Person (personal electric address) attribute comprises from the set such as the type that derives EMailAddress (e-mail address) and the TelephoneNumber EAdress (electronic address) such as (telephone numbers).For filtering, must be transformed into the TelephoneNumber type from the EAddress coercion of type based on area code:
// find out in telephone number 425 area codes everyone
FindResult?res1=Person.FindAll(
ctx.
″PersonalEAddresses.″+
″Cast(System.Storage.Contact.TelephoneNumber)).″+
″AreaCode=’425’″);
// or, can following transmission type name:
FindResult?res1=Person.FindAll(
ctx,
String.Format(″PersonalEAddresses.Cast({0})).AreaCode=’425’″,
typeof(TelephoneNumber).FullName))
C) filtrator sentence structure
Below be according to the description of an embodiment by the filtrator sentence structure of storage platform API support.
Filtrator: :=air filter | condition
Air filter: :=
Condition: :=simple condition | compound condition | bracketed condition
Simple condition: :=exist and check this
Exist and check: :=attribute is quoted
Relatively: :=attribute is quoted the comparison operator constant
Compound condition: :=simple condition Boolean operator condition
Bracketed condition: :=' (' condition ') '
Comparison operator: :='!=' | '==' | '=' | '<' | ' ' | '=' | '<='
Boolean operator: :=' And ' | ′ ﹠amp; ﹠amp; ' | ' Or ' | ' || '
Constant: :=string constant | digital constant
The string constant: :=' " (any Unicode character) * ' "
Attention: embedding ' character is by duplicating escape
The numeral constant: :=0-9*
Attribute is quoted: :=simple attributes name | the complex attribute name
The simple attributes name: :=(except that '. ' and the space all Unicode characters) the * filtrator?
Filtrator: :=' (' condition ') '
The complex attribute name: :=(the coercion of type conversion | the relation traversal | the simple attributes name) '. ' attribute is quoted
The coercion of type conversion: :=' Cast (' type name ') '
Relation traversal: :=traverse the source | traverse target
Traverse the source: :=' Source (' completeness relation name ') '
Traverse target: :=' Target (' completeness relation name ') '
Type name: :=complete qualified CLR type name
The completeness relation name: :=schema name '. ' relation name
Schema name: :=storage platform name
The relation name: :=storage platform name
The storage platform name: :=as defined in [mode-definition]
11. remote control
A) this locality among the API/long-range transparency
The target of the data access in the storage platform is local storage platform example.If inquiry (or its part) relates to teledata, then local example is as router.Thus, api layer provides this locality/long-range transparency: do not have structural API difference between local and remote data access.It is to be decided by the scope of being asked purely.
The storage platform data storage has also realized distributed query; Thus, may be connected to local storage platform example, and carry out the inquiry that comprises from the project of difference volume, wherein certain some project is stored in this locality, and other project is on remote storage.Storage is carried out and operation the result, and is presented to application program.From the viewpoint (being the viewpoint of application developer therefore) of storage platform API, any remote access is seamless and transparent fully.
Storage platform API allows application program to use the IsRemote attribute to determine that given ItemContext object (as being returned by the ItemContext.Open method) is expression this locality or long-range connection, and this attribute is the attribute on the ItemContext object.Especially, application program may be desirable to provide video feed and helps for performance, reliability etc. user expectation is set.
B) storage platform of remote control realizes
The storage platform data storage uses special OLEDB supplier to talk to each other, and this supplier moves (the OLEDG supplier of acquiescence uses TDS) on HTTP.In one embodiment, distributed query is by the acquiescence OPENROWSET function of relevant database engine.Provide a kind of special user-defined function (UDF): DoRemoteQuery (server, queryText), to finish actual remote control.
C) the non-storage platform storage of visit
In an embodiment of storage platform of the present invention, there is not the non-general supplier's architecture that allows any storage to participate in the storage platform data access.Yet, for the particular case of Microsoft Exchange and Microsoft ActiveDirectory (AD) provides limited supplier's architecture.This means the developer can as in storage platform, use storage platform API and visit AD and Exchange in data, but the data that they can visit are limited to the type of storage platform medelling.Thus, in AD, support address book (set of=storage platform Person type), and Exchange is supported mail, calendar and contact person.
D) with the relation of DFS
The point of fixity that storage platform attribute upgrading device is not upgraded and.Even name space is enough abundant to visit by point of fixity, inquiry still can not be passed through them.The leaf node that the storage platform volume can be used as in the DFS tree occurs.
E) with the relation of GXA/Indigo
The developer can use storage platform API to show " GXA head " above data storage.Conceptive, create any other web service without any difference.Storage platform API does not use GXA and storage platform data storage talk.As mentioned above, API uses TDS and local storage talk; Any remote control uses synchronous service to handle by this locality storage.
12. constraint
The storage platform data model allows the value constraint on the type.These constrain in storage and go up assessment automatically, and this process is transparent for the user.Note, check constraint at the server place.Notice after this point that expectation sometimes gives the developer and verifies that the input data satisfy the dirigibility of constraint and can not cause round overhead to server.The interactive application that this final user's input therein is used for the data of filled object is particularly useful.Storage platform API provides this instrument.
Can recall in the XML document and decide the storage platform pattern, it is used to generate the appropriate databases object of this pattern of expression by storage platform.It during also by the design of storage platform API framework be used for generating automatically class.
Below be the part inventory that is used to generate the XML file of Contacts pattern:
<Schema?Name=″Contacts″MajorVersion=″1″MinorVersion=″8″>
<ReferencedSchema?Name=″Base″MajorVersion=″1″/>
<Type?Name=″Person″MajorVersion=″1″?MinorVersion=″0″
ExtendsType=″Principal″ExtendsVersion=″1″>
<Field?Name=″Birthdate″Type=″the?storage?platformTypes.datetime″
Nullable=″true″MultiValued=″false″/>
<Field?Name=″Gender″Type=″the?storage?platformTypes.nvarchar(16)″
Nullable=″true″MultiValued=″false″/>
<Field?Name=″PersonalNames″Type=″FullName″TypeMajorVersion=″1″
Nullable=″true″MultiValued=″true″/>
<Field?Name=″PersonalEAddresses″Type=″EAddress″
TypeMajorVersion=″1″Nullable=″true″MultiValued=″true″/>
<Field?Name=″PersonalPostalAddresses″Type=″PostalAddress″
TypeMajorVersion=″1″Nullable=″true″MultiValued=″true″/>
<Check>expression</Check>
</Type>
...
...
</Schema>
Check label among the above XML has been specified the constraint on the Person type.An above Check label can be arranged.More than constraint is generally checked in storage.Also can check that above XML is modified to for specifying constraint by the application program explicitly:
<Schema?Name=″Contacts″MajorVersion=″1″MinorVersion=″8″>
<ReferencedSchema?Name=″Base″MajorVersion=″1″/>
<Type?Name=″Person″...>
<Field?Name=″Birthdate″Type=″the?storage?platformTypes.datetime″
Nullable=″true″MultiValued=″false″/>
...
<Check?InApplication=″true″>expression</Check>
</Type>
...
...
</Schema>
Note<Check〉new " InApplication " attribute on the element is set as very.This causes storage platform API in API constraint to be placed the surface by the case method that is called Validate () on the Person class.Application program can be called this method on object, be effectively to guarantee data, and prevents possible useless the coming and going to server.This returns the result's of indication affirmation Boolean.Notice that the value constraint is still used at the server place, no matter and client computer whether called<object .Validate () method.Below be an example how using Validate:
ItemContext?ctx=ItemContext.Open();
// in user's My Contacts file, create the contact person.
Folder?f=UserDataFolder.FindMyPersonalContactsFolder(ctx);
Person?p=new?Person(f);
// people's birthday is set
p.Birthdate=new?DateTime(1959,6,9);
// interpolation is classified as the name of name
FullName?name=new?FullName(FullName.Category.PrimaryName);
name.GivenName=″Joe″;
name.Surname=″Smith″;
p.PersonalNames.Add(name);
// affirmation Person object
if(p.Validate()==false)
{
// data are not represented effective people
}
// preservation changes
p.Update();
ctx.Close();
Many access path-storage platform API, ADO.NET, ODBC, OLEDB and ADO having the storage platform storage.This has caused the problem that authoritative constraint checks-promptly, how to guarantee to retrain by identical data integrity from for example the ODBC data of writing out and the data of writing out from storage platform API.Because all constraints check that at depository therefore constraint is authoritative now.No matter the API path that is used to arrive storage how, all of storage are write all filter by the constraint inspection of depository.
13. share
Shared in the storage platform is following form:
<dns name<the context service
Wherein<and dns name〉be the dns name of machine, the service of<context〉be include file folder, virtual folder or the project in the volume on this machine.For example, suppose that machine " Johns_Desktop " has the volume of Johns_Information by name, and in this volume, have the file of Contacts_Categories by name; This document clip pack contains the file of Work by name, and the latter has the working relation people of John:
\\Johns_Desktop\Johns_Information$\Contacts_Categories\Work
This can be shared as " WorkContacts ".Adopt this definition of sharing, Johns_Desktop WorkContacts JaneSmith be effective storage platform name, and identified Person project JaneSmith.
A) expression is shared
Shared item types has following attribute: shared name and shared target (this can be the non-link of holding).For example, above-mentioned shared title is WorkContacts, and target be the Contacts_Categories of volume on the Johns_Information Work.Below be the schema fragment that is used for the Share type:
<Schema
xmlns=″http://schemas.microsoft.com/winfs/2002/11/18/schema″
Name=″Share″MajorVersion=″1″MinorVersion=″0″>
<ReferencedSchema?Name=″Base″MajorVersion=″1″/>
<ReferencedSchema?Name=″the?storage?platformTypes″MajorVersion=″1″/>
<Type?Name=″Share″MajorVersion=″1″MinorVersion=″0″
ExtendsType=″Base.Item″ExtendsVersion=″1″>
<Field?Name=″Name″Type=″the?storage?platformTypes.nvarchar(512)″
TypeMajorVersion=″1″/>
<Field?Name=″Target″Type=″Base.RelationshipData″TypeMajorVersion=″1″/>
</Type>
</Schema>
B) management is shared
Because sharing is a project, therefore shares and to manage as other project.Share and to be created, to delete and to revise.Share and also protect in the mode the same with other storage platform items.
C) visit is shared
Application program by in ItemContext.Open () method call with shared name (for example, Johns_Desktop WorkContacts) be delivered to storage platform API and visit the remote storage platform and share.ItemContext.Open returns the ItemContext object instance.Storage platform API talks (can recall visit remote storage platform finishes by local storage platform) then with local storage platform service.Local storage platform service so with have given shared name (for example, remote storage platform service WorkContacts) (for example, at machine Johns_Desktop) talk.The remote storage platform service then WorkContacts is converted to Contacts_Categories Work and open it.After that, carry out the same with other scope inquired about and other operation.
D) property found
In one embodiment, application program can be found given<dns name with the following methods〉upward available sharing.According to first kind of mode, storage platform API accept dns name (for example, Johns_Desktop), as the range parameter in the ItemContext.Open () method.Storage platform API is connected to the storage platform storage with this dns name as a part that connects string then.Adopt this connection, the unique thing that can do of application program is to call ItemContext.FindAll (typeof (Share)).Storage platform service is shared on all additional volumes all then and is carried out and operation, and returns and share set.According to the second way, on local machine, the keeper can pass through FindAll (typeof (Share)) and find sharing on the certain volume, or finds specific file by FindAll (typeof (Share), " Target (ShareDestination) .Id=folderId ").
14.Find semanteme
Find* method (no matter they are to call at the ItemContext object or on individual other project) generally is applied to the project (project that comprises embedding) in the given context.Nested element does not have Find-, and they can not be independent of it and comprise project search.This and desired semantic consistent of storage platform data model, wherein nested element derives its " identity " from comprising project.For making this notion clearer, below be effective and the example of invalid search operation:
A) all telephone numbers that have area code 206 in the system are shown?
Invalid, finish because this is searched on telephone number (element), and do not have REFER object.
B) all telephone numbers that have area code 206 in all Person are shown?
Invalid, even quoted Person (=project), search criteria does not relate to this project yet.
C) all telephone numbers with area code 206 of Murali (=single people) are shown?
Effectively, because there is search criteria on the project Person of (by name " Murali ").
The exception of this rule is the nested element that derives from the Base.Relationship type for directly or indirectly.These types can individually be inquired about by relation object.This inquiry can be supported, because storage platform realizes having adopted " main chain table " to store the Relationship element but not they are embedded among the project UDT.
15. storage platform Contacts API
This section has provided the summary of storage platform Contacts API.Contacts API pattern behind is shown in Figure 21 A and the 21B.
A) summary of System.Storage.Contact
Storage platform API comprises and is used for handling the project of contact schema and the name space of element.This name space is called as System.Stroage.Contact.
This pattern has for example with lower class:
Project: UserDataFolder, User, Person, ADService, Service, Group, Organization, Principal, Location
Element: Profile, PostalAddress, EmailAddress, TelephoneNumber, RealTimeAddress, Eaddress, FullName, BasicPresence, GroupMembership, RoleOccupancy
B) territory behavior
It below is the tabulation of the territory behavior of contact schema.When sufficiently high rank is checked, the territory behavior falls into the classification of good organization:
Static assistant for example creates new individual contact person's Person.CreatePersonalContact ();
The example assistant for example signs in to user's (example of User class) user.AutoLoginToAllProfiles () of all overviews that are marked as automatic login;
Classification GUID, for example Category.Home, Category.Work etc.;
Derive attribute, for example emailAddress.Address ()-the return user name of the given emailAddress of combination (example of EmailAddress class) and the string of territory field; And
Derive set, for example the example of the given Person class of person.PersonalEmailAddress-obtains its personal email address.
Following table has provided the tabulation of these methods and the classification under them to each class that has the territory behavior among the Contacts.
Figure C0382694101401
Figure C0382694101411
16. storage platform File API
This section has provided the summary of storage platform File API according to one embodiment of the present of invention.
A) introduce
(1) reflection NTFS volume in storage platform
Storage platform provides the method for the enterprising line index of content in existing NTFS volume.This is by extraction (" upgrading ") attribute in each document flow from NTFS or the catalogue, and these attributes are realized in storage platform as items storing.
The file mode of storage platform has defined two kinds of item types-File (file) and Directory (catalogue), stores the file system entity of upgrading.The Directory type is the subtype of Folder type; It is the include file folder that comprises other Directory project or File project.
The Directory project can comprise Directory and File project; It can not comprise the project of any other type.As for the storage platform of being considered, Directory and File project all are read-only from any data access API.File system upgrade manager (FSPM) service is upgraded to the attribute that changes in the storage platform asynchronously.The attribute of File and Directory project can be changed by Win32 API.Storage platform API can be used for reading any attribute of these projects, comprises the stream that is associated with the File project.
(2) in the storage platform name space, create file and catalogue
When the NTFS volume was upgraded to the storage platform volume, All Files wherein and catalogue were all in the specific part of this volume.This zone is read-only from the viewpoint of storage platform; FSPM can create new directory and file, and/or changes the attribute of off-the-shelf item.
The remainder of the name space of this volume can comprise common gamut-Principal (main body), Organization (tissue), Document (document), the Folder (file) etc. of storage platform items type.Storage platform also allows to create file and catalogue in any part of storage platform name space.These " this machine " files and catalogue do not have homologue in new technology file system; They are stored in the storage platform fully.In addition, the change to attribute is visible immediately.
Yet it is identical that programming model keeps; With regard to considering storage platform data access API, they are still read-only." this machine " file and catalogue must use Win32 API to upgrade.This has simplified developer's thinking model, and this thinking model is:
1. any storage platform items type can locating Anywhere in name space be created (certainly, unless licensed the prevention);
2. any storage platform items type can use storage platform API to read;
3. all storage platform items types can use the storage platform API of the exception with File and Directory to write
For writing File and Directory project no matter they in name space where, use Win32API; And
5. the change to the File/Directory project may directly not appear in the storage platform in " upgrading " name space; In " non-upgrading " name space, change and directly in storage platform, reflect.
B) file mode
Figure 25 show File API based on pattern.
C) summary of System.Storage.Files
Storage platform API comprises the name space that is used to handle file object.This name space is called System.Storage.Files.The data member of the class among the System.Storage.Files has directly reflected the information that is stored in the storage platform storage; This information maybe can use this machine of Win32 API to create from file system object " upgrading ".The System.Storage.Files name space has two class: FileItem (docuterm) and DirectoryItem (directory items).The member of these classes and method thereof can easily be guessed by checking the mode chart among Figure 25.FileItem and DirectoryItem are read-only from storage platform API.For revising them, must use the class among Win32 API or the System.IO.
D) example code
In this section, three example codes are provided, show the use of the class among the System.Storage.Files.
(1) opens file and write to it
How this example finishes " tradition " file manipulation if showing.
ItemContext?ctx=ItemContext.Open();
FileItern?f=FileItem.FindByPath(ctx,@″\My?Documents\billg.ppt″);
The example of // processing file attribute-guarantee that file is not read-only
if(!f.IsReadOnly)
{
FileStream?fs=f.OpenWrite();
// reading and writing, close file stream fs
}
ctx.Close();
The 3rd enforcement has used FindByPath (according to path searching) method to open file.The 7th row shows the use to the attribute IsReadOnly of upgrading, checks whether file can be write.If then exercise and obtain document flow with the OpenWrite () method on the FileItem object the 9th.
(2) use inquiry
Because the storage platform storage is held from the attribute of file system upgrading, therefore may easily finish abundant inquiry on file.In this example, listed the All Files of revising in the end three days:
// be listed in last three days the All Files of revising
FindResult?result=Fileltem.FindAll(
ctx,
″Modified>=′{0}′″,
DateTime.Now.AddDays(-3));
Foreach (the FileItem file among the result)
{
...
}
Below be to use another example-this example of inquiry find out a certain type (but=extension) all written documents:
// find out that all can write the .cs file in the particular category
// be equivalent to: dir c: win src api * .cs/a-r-d
DirectoryItem?dir=
DirectoryItem.FindByPath(ctx,@″c:\win\src\api″);
Find?Result=dir.GetFiles(
″Extension=′cs′and?IsReadOnly=false″);
Foreach (the File file among the result)
{
...
}
E) territory behavior
In one embodiment, except that standard attribute and method, files classes also have territory behavior (attribute of manual coding and method).These behaviors are generally based on the method in the System.IO class of correspondence.
J. sum up
As mentioned above, the present invention is directed to a kind ofly be used to organize, the storage platform of search and shared data.Storage platform of the present invention expands and has widened the notion of data storage outside existing file system and Database Systems, and be designed to store all types of data, comprise structurized, non-structured or semi-structured data, such as relationship type (tabular form) data, XML and the data that are called the new model of project.By the data of its common storage basis and medelling, storage platform of the present invention allows more effective application development to consumer, Knowledge Worker and enterprise.It provides a kind of abundant and extendible application programming interface, and this interface not only makes the capability in its data model to use, and also comprises and has expanded existing file system and data bank access method.Be appreciated that and make a change the foregoing description and do not break away from its wide in range inventive concepts.Therefore, the invention is not restricted to the specific embodiment that disclosed, and be intended to cover all modifications that falls into by within the spirit and scope of the present invention of appended claims definition.
As from above can be clearly, all or part of form of program code (that is instruction) of can using of various systems of the present invention, method and aspect be implemented.This program code can be stored on the computer-readable medium, such as the magnetic, electrical, optical storage medium, include but not limited to, floppy disk, CD-ROM, CD-RW, DVD-ROM, DVD-RAM, tape, flash memory, hard disk drive or any other machinable medium, wherein, when program code is loaded into when carrying out such as machines such as computing machine or servers and by it, this machine becomes and is used to realize device of the present invention.The present invention is also available by a certain transmission medium, such as by electric wire or cable, implement by optical fiber, network by comprising the Internet or Intranet or the form of the program code that transmits by the transmission of any other form, wherein, when program code by accepting and be loaded into such as machines such as computing machines when wherein carrying out by it, this machine becomes and is used to realize device of the present invention.When on general processor, realizing, the unique apparatus that program code combines with processor and is similar to the particular logic circuit operation to provide.
Appendix A
namespace?System.Storage
{
abstract?class?ItemContext:IDisposable,IServiceProvider
{
ItemContext creates and the management member
// application program can't directly be created the ItemContext object, also can't derive class from ItemContext.
internal?itemContext();
// create and can be used for searching for specified path, if perhaps specified path not,
// then establishment can be used for searching for the ItemContext of the default storage on the local computer.
public?static?ItemContext?Open();
public?static?ItemContext?Open(string?path);
public?static?ItemContext?Open(params?string[]paths);
The path of // appointment when returning establishment ItemContext.
public?string[]GetOpenPaths();
The copy of this ItemContext of // establishment.This copy will have independently affairs, high-speed cache and update mode.High-speed cache
// be initially sky.It is more effective that expectation uses clone's ItemContext to open new ItemContext than use same project territory.
public?ItemContext?Clone();
// close ItemContext.After closing, use any trial of ItemContext will cause ObjectDisposedException.
public?void?Close();
void?IDisposable.Dispose();
If // when any territory of opening the ItemContext appointment is resolved to remote computer, then be true.
public?bool?IsRemote{get;}
// return the object that institute's requested service type can be provided.If institute's requested service can not be provided, then return sky.
// API that the use of IServiceProvider pattern is allowed improper use and may cause the developer to obscure is excluded
Outside the //ItemContext class.ItemContext can provide the service of following kind: ItemSerialization, IStoreObjectCachepublic object GerService (rype serviceType);
Upgrade relevant member
// preserve by the object of all modifications and be delivered to MarkForCreate or the change of all object representations of MarkForDelete.
If // detecting update inconsistency, UpdateCollisionException then can dish out.
public?void?Update();
// preservation is by the change of specified object representation.Object must be modified or be passed to MarkForCreate or
//MarkForDelete, otherwise the ArgumentException that dishes out.If detect update inconsistency,
// UpdateCollisionException can dish out.
public?void?Update(object?objectToUpdate);
public?void?Update(IEnumerable?objectsToUpdate);
// from storage, refresh the content of specified object.If object is modified, then cover change, and object is considered to no longer
// change.If specified any content except that project, project expansion or relationship object, ArgumentException then dishes out.
public?void?Refresh(object?objectToRefresh);
public?void?Refresh(IEnumerable?objectsToRefresh);
// detect the object that retrieval revises and attempt to preserve and cause when in storage, having changed data between it when renewal.If registration is not appointed
// what part handling procedure then upgrades and dishes out unusually.If registered button.onrelease, then it can be dished out and end unusually to upgrade,
The object that // packing is revised to be covering the data in the storage, or be incorporated in the storage and object in the change made.
public?event?ChangeCollisionEventHandler?UpdateCollision;
// upgrading the each point place initiation of handling, so that the renewal progress information to be provided.
public?event?UpdateProgressEventhandler?UpdateProgress;
The asynchronous version of //Update
public?IAsyncResult?BeginUpdate(IAsyncCallback?callback,object?state);
public?IAsyncResult?BeginUpdate(object?objectToUpdate,
IAsyncCallback?callback,
object?state);
public?IAsyncResult?BeginUpdate(IEnumerable?objectsToUpdate,
IAsyncCallback?callback,
object?state);
public?void?EndUpdate(IAsyncResuIt?result);
The asynchronous version of //Refresh
public?IAsyncResult?BeginRefresh(object?objectToRefresh,
IAsyncCallback?callback,
object?state);
public?IAsyncResult?BeginRefresh(IEnumerable?objectsToRefresh,
IAsyncCallback?callback,
object?state);
public?void?EndRefresh(IAsyncResult?result);
The affairs member that is correlated with
// start affairs with the isolation level of appointment.The isolation level of acquiescence is ReadCommited.In all cases,
// start distributed transaction, because may must comprising, it changes the stream type item attribute.
public?Transaction?BeginTransaction();
public?Transaction?BeginTransaction(System.Data.IsolationLevel?isolationLevel);
The relevant member of search
// be created in this project context the ItemSearcher of search specified type object.If specified the project of removing, relation or
Type outside the expansion of // project, ArgumentException then dishes out.
public?ItemSearcher?GetSearcher(Type?type);
// given its ID finds out project.
public?Item?FindItemById(ItemId?ItemId);
Project is found out in // given its path.The path can be absolute or relative.If relative, if then when opening ItemContext
In // time, specified a plurality of item domains, and NotSupportedException then dishes out.If there is no such project is then returned sky.
// be created to the territory machine the connection of share part with search terms.This project will be associated with this territory.
public?Item?FinditemByPath(string?path);
Project is found out in // given its path.The path is with respect to the item domains of appointment.The connection that is created to specified domain is with search terms.This project will
// be associated with this territory.If there is no such project is then returned sky.
public?Item?FindItemByPath(string?domain,string?path);
One group of project is found out in // given its path.This path is with respect to the item domains of appointment when opening ItemContext.If there is no
// such project is then returned the sky result.
public?FindResult?FindAllItemsByPath(string?path);
// given its ID finds out relation.
public?Relationship?FindRelationshipById(ItemId?itemID,
RelationshipId?relationshipId);
// given its ID finds out the project expansion.
public?ItemExtension?FindItemExtensionById(ItemId?itemId,
ItemExtensionId?itemExtensionId);
// find out all items, relation or the project that can at random satisfy the specified type of given filtrator to expand.If specified
Type beyond one of // these types, ArgumentException then dishes out.
public?FindResult?FindAll(Tyoe?type);
public?FindResult?FindAll(Type?type,string?filter);
// find out any project, relation or the project expansion of the specified type that satisfies given filtrator.If specified one of these types
// in addition type, ArgumentException then dishes out.If do not find such object, then return sky.
public?object?FindOne(Type?type,string?filter);
// find out project, relation or the project expansion of the specified type that satisfies given filtrator.If specified beyond one of these types
// type, ArgumentException then dishes out.If do not find such object, then dish out
//ObjectNotFoundException。If find an above object, MultipleObjectsFoundException then dishes out.
public?object?FindOnly(Type?type,string?filter);
If // there are project, relation or the project expansion of the specified type that satisfies given filtrator, then return true.If specified these
Type beyond one of // type, ArgumentException then dishes out.
public?bool?Exists(Type?type,string?filter);
// specify the object that returns by the search that relates to object how to identify the mapping of safeguarding by ItemContext.
public?SearchCollisionMode?SearchCollisionMode{get;set;}
// when having specified PreserveModifiedO bject, cause for ResultMapping.This incident allows application program optionally to use
// retrieve the object that Russia's data are upgraded modification with this search.
public?event?ChangeCollisionEventHandler?SearchCollision;
// will be attached to from the object of another ItemContext in this project context.If expression same project, relation or project expansion
// object does not exist in the identity map of this ItemContext, then creates the clone of this object and adds it to this mapping.If
// object exists really, and then the state with appointed object upgrades this object with content in the mode consistent with SearchCollisionMode.
public?Item?IncorporateItem(Item?item);
public?Relationship?IncorporateRelationship(Relationship?relationship);
public?ItemExtension?IncorporateItemExtension(ItemExtension?itemExtension);
}
// be used for the handling procedure of ItemContext.UpdateCollision and ItemSearcher.SearchCollision incident.
public?delegate?void?ChangeCollisionEventHandler(object?source,
ChangeCollisionEventArgs?args);
// be used for the independent variable that ChangeCollisionEventHandler entrusts
public?class?ChangeCollisionEventArgs:EventArgs
{
The project of // modification, project expansion or relationship object.
public?obiect?ModifiedObject{get;}
// from the attribute of storing
public?IDictionary?StoredProperties{get;}
}
// be used for the handling procedure of ItemContext.UpdateProgress
public?delegate?void?UpdateProgressEventHandler(ItemContext?itemContext,
UpdateProgressEventArgs?args);
// be used for the independent variable that UpdateProgressEventHandler entrusts
public?class?ChangeCollisionEventArgs:EventArgs
{
// current renewal operation
public?UpdateOperation?CurrentOperation{get;}
The object of // current renewal
public?object?CurrentObject{get;}
}
// specify the object that returns by the search that relates to object how to identify the mapping of safeguarding by ItemContext.
public?enum?SearchCollisionMode
{
New object should be created and return to // indication.Ignore the object of representing same project, project expansion or relation in the identity map.If
// specified this option, then do not cause the SearchCollision incident.
DoNotMapSearchResults,
// indication should be returned the object from identity map.If application modification the content of object, the content of the object of then preserve revising.
If // unmodified object is then used its content of Data Update of being returned by search.Application program can be provided for SearchCollision
The handling procedure of // incident, and upgating object optionally when needed.
PreserveModifiedObjects,
// indication should be returned the object from identity map.The content of the Data Update object that use is returned by search is even object is employed
// modification of program.If specified this option, then do not cause the SearchCollision incident.
OverwriteModifiedObjects
}
// current renewal operation
public?enum?UpdateOperation
{
// when calling Update first, provide.CurrentObject will be sky.
OverallUpdateStarting,
// only the Update after successfully upgrading provides before returning.CurrentObject will be sky.
OverallUpdateCompletedSuccessfully,
// only before dishing out unusually, Update provides.CurrentObject will be an exception object.
OverallUpdateCompletedUnsuccessfully,
// when starting the renewal of object, provide.CurrentObject will quote the object that is used to upgrade.
ObjectUpdateStaring,
// when newly connecting, needs provide.CurrentObject will comprise the sign pass to ItemContext.Open or from the relation
The string in the path of the item domains of //location field retrieval.
OpeningConnection
}
}
Appendix B
namespace?System.Storage
{
// search of particular type is striden in execution in the project context.
public?class?ItemSearcher
{
Constructed fuction
public?ItemSearcher();
public?ItemSearcher(Type?targetType,ItemContext?context);
public?ItemSearcher(Type?targetType,ItemContext?context,
params?SearchExpression[]filters);
Attribute
// be used for the filtrator of marking matched object.
public?SearchExpressionCollection?Filters{get;}
// appointment is with the ItemContext in searched territory.
public?ItemContext?ItemContext{get;set;}
The set of // search parameter.
public?ParameterCollection?Parameters{get;}
// searcher will be used for operation types.For simple search, this is the type of the object that will return.
public?Type?TargetType{get;set;}
Searching method
// find out the object that satisfies by the TargetType of the condition of Filters appointment.If there is no such object then returns empty
//FindResult。
public?FindResult?FindAll();
public?FindResult?FindAll(FindOptions?findOptions);
public?FindResult?FindAll(params?SortOption[]sortOptions);
// find out any one object that satisfies by the TargetType of the condition of Filters appointment.If there is no such object then returns sky.
public?object?FindOne();
public?object?FindOne(FindOptions?findOptions);
public?object?FindOne(params?SortOption[]sortOptions);
// find out the TargetType that satisfies by the condition of Filters appointment.If do not find such object then dish out
//ObiectNotFoundException。If find an above object, MultipleObjectsFoundException then dishes out.
public?object?FindOnly();
public?object?FindOnly(FindOptions?findOptions);
Whether // the object that determine to satisfy by the TargetType of the condition of Filters appointment exists.
public?bool?Exists();
// establishment can be used for more effectively repeating the object of same search.
public?PreparedFind?PrepareFind();
public?PreparedFind?PrepareFind(FindOptions?findOptions);
public?PreparedFind?PrepareFind(params?SortOption[]sortOptions);
The number of the record that // retrieval will be returned by FindAll ().
public?int?GetCount();
The asynchronous version of // the whole bag of tricks
public?IAsyncResult?BeginFindAll(AsyncCallback?callback,
object?state);
public?IAsyncResult?BeginFindAll(FindOptions?findOptions,
AsyncCallback?callback,
object?state);
public?IAsyncResult?BeginFindAll(SortOption[]sortOptions,
AsyncCallback?callback,
object?state);
public?FindResult?EndFindAll(IAsyncResult?ar);
public?IAsyncResult?BeginFindOne(AsyncCallback?callback,
object?state);
public?IAsyncResult?BeginFindOne(FindOptions?findOptions,
AsyncCallback?callback,
object?state);
public?IAsyncResult?BeginFindOne(SortOption[]sortOptions,
AsyncCallback?callback,
object?state);
public?object?EndFindOne(IAsyncResult?asyncResult);
public?IAsyncResult?BeginFindOnly(AsyncCallback?callback,
object?state);
public?IAsyncResult?BeginFindOnly(FindOptions?findOptions,
AsyncCallback?callback,
object?state);
public?IAsyncResult?BeginFindOnly(SortOption[]sortOptions,
AsyncCallback?callback,
object?state);
public?object?EndFindOnly(IAsyncResult?asyncResult);
public?IAsyncResult?BeginGetCount(AsyncCallback?callback,
object?state);
public?int?EndGetCount(IAsyncResult?asyncResult);
public?IAsyncResult?BeginExists(AsyncCallback?callback,
object?state);
public?bool?EndExists(IAsyncResult?asyncResult);
}
The option of // use when carrying out search
public?class?FindOptions
{
public?FindOptions();
public?FindOptions(params?SortOption[]sortOptions);
// specify whether to postpone to load the field that can postpone to load.
public?bool?DelayLoad{get;set;}
The number of // the coupling returned.
public?int?MaxResults{get;set;}
The set of // sort options.
public?SortOptionCollextion?SortOptions{get;}
}
// expression parameter name and value
public?class?Parameter
{
// use title and the Parameter of value initialization object
public?Parameter(string?name,object?value);
// parameter name
public?string?Name{get;}
// parameter value
public?object?Value{get;set;}
}
The set that // parameter name/value is right
public?class?ParameterCollection:ICollection
{
public?ParameterCollection();
public?int?Count{get;}
public?object?this[string?name]{get;set;}
public?object?SyncRoot{get;}
public?void?Add(Parameter?parameter);
public?Parameter?Add(string?name,object?value);
public?bool?Contains(Parameter?parameter);
public?bool?Contains(string?name);
public?void?CopyTo(Parameter[]array,int?index);
void?ICollection.CopyTo(Array?array,int?index);
IEnumerator?IEnumerable.GetEnumerator();
public?void?Remove(Parameter?parameter);
public?void?Remove(string?name);
}
// expression capable the search of optimizing of retry of having attached most importance to.
public?class?PreparedFind
{
public?ItemContext?ItemContext{get;}
public?ParameterCollection?Parameters{get:}
public?FindResult?FindAll();
public?object?FindOne();
public?object?FindOnly();
public?bool?Exists();
}
The sort options that uses in // appointment the search.
public?class?SortOption
{
// the initialization object Uses Defaults.
public?SortOption();
// use SearchExpression, order initialization SortOptions object.
public?sortOption(SearchExpression?searchExpression,SortOrder?order);
// sign is with the search SearchExpression of the attribute of ordering.
public?SearchExpression?Expression{get;set;}
The clooating sequence of // appointment ascending order or descending
public?SortOrder?Order{get;set;}
}
The set of // sort options object
public?class?SortOptionCollection:IList
{
public?SortOptionCollection();
public?SortOption?this[int?index]{get;set;}
public?int?Add(SortOption?value);
public?int?Add(SearchExpression?expression,SortOrder?order);
int?IList.Add(object?value);
public?void?Clear();
public?bool?Contains(SortOption?value);
bool?IList.Contains(object?value);
public?void?CopyTo(SortOption[]array,int?index);
void?ICollection.CopyTo(Array?array,int?index);
public?int?Count{get;}
IEnumerator?IEnumerable.GetEnumerator();
public?void?Insert(int?index,SortOption?value);
void?IList.Insert(int?index,object?value);
public?int?indexOf(SortOption?value);
int?IList.IndexOf(object?value);
public?void?Remove(SortOption?value);
void?IList.Remove(object?value);
public?void?RemoveAt(int?index);
public?object?SyncRoot{get;}
}
// use the SortOption object to specify clooating sequence
public?enum?SortOrder
{
Ascending,
Descending
}
}
Appendix C
namespace?System.Storage
{
public?abstract?class?FindResult:IAsyncObjectReader
{
public?FindResult();
// FindResult is moved to the next position among the result.
public?bool?Read();
public?IAsyncResult?BeginRead(AsyncCallback?callback,object?state);
public?bool?EndRead(IAsyncResult?asyncResult);
// current object.
public?object?Current{get;}
// return FindResult and whether comprise any object.
public?bool?HasResults{get;}
// return FindResult whether to be closed.
public?bool?IsClosed{get;}
// return the type of the project among this FindResult.
public?Type?ObjectType{get;}
// close FindResult
public?void?Close();
void?IDisposable.Dispose();
// return the enumerator on the FindResult, from current location.Any enumerator that advances on FindResult will advance all
// enumerator and FindResult itself.
IEnumerator?IEnumerable.GetEnumerator();
public?FindResultEnumerator?GetEnumerator();
}
public?abstract?class?FindResultEnumerator:IEnumerator,IDisposable
{
public?abstract?object?Current{get;}
public?abstract?bool?MoveNext();
public?abstract?void?Reset();
public?abstract?void?Close();
void?IDisposable.Dispose();
}
}
namespace?System
{
// be used for the common interface of iteration on object
public?interface?iObjectReader:IEnumerable,IDisposable
{
object?Current{get;}
bool?IsClosed{get;}
bool?HasResults{get;}
Type?objectType{get;}
bool?Read();
void?Close();
}
// add asynchronous method to IObjectReader
public?interface?IAsyncObjectReader:IObjectReader
{
IAsyncResult?BeginRead(AsyncCallback?callback,object?state);
bool?EndRead(IAsyncResult?result);
}
}

Claims (12)

1. storage platform system comprises:
The hardware/software interface module, bottom hardware assembly that described hardware/software interface module is a computer system and the interface between the application program of carrying out on the computer system;
Data memory module, wherein stored data are according to project, element and relation define, wherein, project be can be stored in the described data memory module message unit and can be by the visit of described hardware/software interface module, and described project is to have one group of object that is represented the base attribute of supporting jointly to all objects of final user by the hardware/software interface module, wherein said project also comprises one or more elements and relation, element is the example of type, comprise one or more described base attributes, and relation is the link between at least two projects;
The mode development tool model is used to provide the modal sets that defines dissimilar project, element and relation; And
The application programming interface module, it generates a class to each of the disparity items, element and the relation that define in the described modal sets.
2. storage platform as claimed in claim 1 system, it is characterized in that, data also can be stored in the described data memory module with the form to the expansion of off-the-shelf item type, and wherein, described application programming interface module is to class of each different project expanded definition.
3. storage platform as claimed in claim 1 system is characterized in that, the class of project, element and the relation of each type is based on the described modal sets of project, element and the relation of each type of definition generates automatically.
4. storage platform as claimed in claim 1 system, it is characterized in that, to the class definition of project, element and the relation of each type one group of data class, and wherein, described application programming interface module also is included as second category that described data class defines one group of public behavior.
5. storage platform as claimed in claim 4 system, it is characterized in that, described second category comprises expression storage platform system scope and for the inquiry on the described data memory module provides the contextual first kind, and second class of representing the result of the inquiry on the described data memory module.
6. storage platform as claimed in claim 1 system, it is characterized in that, also comprise the database engine of realizing described data memory module on it, and wherein, dissimilar project, element and passes ties up to and is implemented as user defined type UDT in the described database engine in the described data memory module.
7. storage platform as claimed in claim 6 system, it is characterized in that, described application programming interface module provides an interrogation model, described interrogation model makes that the application programmer can be in the mode that the details of the query language of described application programmer and described database engine is isolated, and forms inquiry based on the various attributes of the project in the described data memory module.
8. one kind is used to provide application program and is used for storage, tissue, share and the storage platform system of search data between the method for application programming interface module, wherein said storage platform system comprises data memory module, wherein stored data are according to project, element and relation define, wherein project is that the message unit that can be stored in the described data memory module also can be visited by the hardware/software interface module, bottom hardware assembly that described hardware/software interface module is a computer system and the interface between the application program of carrying out on the computer system, and described project is to have one group of object that is represented the base attribute of supporting jointly to all objects of final user by the hardware/software interface module, wherein said project also comprises one or more elements and relation, element is the example of type, comprise one or more described base attributes, and relation is the link between at least two projects, said method comprising the steps of:
The modal sets of dissimilar project, element and relation of definition is provided; And
For each of the different projects, element and the relation that define in the described modal sets generates a class, as the part of described application programming interface module.
9. method as claimed in claim 8 is characterized in that, data also can be stored in the described data memory module with the form to the expansion of off-the-shelf item type, and wherein, described method also is included as each different projects expansion and generates a class.
10. method as claimed in claim 9, it is characterized in that, the class definition that generates for the project of each type, element and relation one group of data class, and wherein, described method also comprises and is provided as second category that described data class defines one group of public behavior, as the step of an extra section of described application programming interface module.
11. method as claimed in claim 10, it is characterized in that, described second category comprises expression storage platform system scope and for the inquiry on the described data memory module provides the contextual first kind, and second class of representing the result of the inquiry on the described data memory module.
12. method as claimed in claim 8, it is characterized in that, the data memory module of described storage platform system is realized on database engine, and wherein, described method also is included in the step that projects dissimilar in the described data memory module, element and relation is embodied as the user defined type UDT in the described data engine.
CNB038269414A 2003-08-21 2003-08-21 Be used for application program and system and method based on the storage platform interface of item Expired - Fee Related CN100550010C (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/US2003/026150 WO2005029363A1 (en) 2003-08-21 2003-08-21 Systems and methods for interfacing application programs with an item-based storage platform

Publications (2)

Publication Number Publication Date
CN1820266A CN1820266A (en) 2006-08-16
CN100550010C true CN100550010C (en) 2009-10-14

Family

ID=34374762

Family Applications (1)

Application Number Title Priority Date Filing Date
CNB038269414A Expired - Fee Related CN100550010C (en) 2003-08-21 2003-08-21 Be used for application program and system and method based on the storage platform interface of item

Country Status (9)

Country Link
EP (1) EP1646954A4 (en)
JP (1) JP2007521533A (en)
KR (1) KR100959473B1 (en)
CN (1) CN100550010C (en)
AU (1) AU2003259961B2 (en)
BR (1) BR0318464A (en)
CA (1) CA2532909A1 (en)
MX (1) MXPA06001984A (en)
WO (1) WO2005029363A1 (en)

Families Citing this family (44)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7590643B2 (en) 2003-08-21 2009-09-15 Microsoft Corporation Systems and methods for extensions and inheritance for units of information manageable by a hardware/software interface system
US8238696B2 (en) 2003-08-21 2012-08-07 Microsoft Corporation Systems and methods for the implementation of a digital images schema for organizing units of information manageable by a hardware/software interface system
US8166101B2 (en) 2003-08-21 2012-04-24 Microsoft Corporation Systems and methods for the implementation of a synchronization schemas for units of information manageable by a hardware/software interface system
US8131739B2 (en) 2003-08-21 2012-03-06 Microsoft Corporation Systems and methods for interfacing application programs with an item-based storage platform
US8613048B2 (en) 2004-09-30 2013-12-17 Citrix Systems, Inc. Method and apparatus for providing authorized remote access to application sessions
US8095940B2 (en) 2005-09-19 2012-01-10 Citrix Systems, Inc. Method and system for locating and accessing resources
US7711835B2 (en) 2004-09-30 2010-05-04 Citrix Systems, Inc. Method and apparatus for reducing disclosure of proprietary data in a networked environment
US7680758B2 (en) 2004-09-30 2010-03-16 Citrix Systems, Inc. Method and apparatus for isolating execution of software applications
US7748032B2 (en) 2004-09-30 2010-06-29 Citrix Systems, Inc. Method and apparatus for associating tickets in a ticket hierarchy
US8171479B2 (en) 2004-09-30 2012-05-01 Citrix Systems, Inc. Method and apparatus for providing an aggregate view of enumerated system resources from various isolation layers
US8024568B2 (en) 2005-01-28 2011-09-20 Citrix Systems, Inc. Method and system for verification of an endpoint security scan
US7756826B2 (en) 2006-06-30 2010-07-13 Citrix Systems, Inc. Method and systems for efficient delivery of previously stored content
US9621666B2 (en) 2005-05-26 2017-04-11 Citrix Systems, Inc. Systems and methods for enhanced delta compression
US8943304B2 (en) 2006-08-03 2015-01-27 Citrix Systems, Inc. Systems and methods for using an HTTP-aware client agent
US9692725B2 (en) 2005-05-26 2017-06-27 Citrix Systems, Inc. Systems and methods for using an HTTP-aware client agent
US9407608B2 (en) 2005-05-26 2016-08-02 Citrix Systems, Inc. Systems and methods for enhanced client side policy
FR2888019A1 (en) * 2005-07-04 2007-01-05 France Telecom METHOD FOR CONSTRUCTING A DIRECTORY DATABASE, COMPUTER PROGRAM PRODUCT AND CORRESPONDING SERVER
US8131825B2 (en) 2005-10-07 2012-03-06 Citrix Systems, Inc. Method and a system for responding locally to requests for file metadata associated with files stored remotely
US7779034B2 (en) 2005-10-07 2010-08-17 Citrix Systems, Inc. Method and system for accessing a remote file in a directory structure associated with an application program executing locally
US20070174429A1 (en) 2006-01-24 2007-07-26 Citrix Systems, Inc. Methods and servers for establishing a connection between a client system and a virtual machine hosting a requested computing environment
US7624349B2 (en) * 2006-03-21 2009-11-24 Microsoft Corporation Declarative definition enabling graphical designer reuse
US8533846B2 (en) 2006-11-08 2013-09-10 Citrix Systems, Inc. Method and system for dynamically associating access rights with a resource
US7853678B2 (en) 2007-03-12 2010-12-14 Citrix Systems, Inc. Systems and methods for configuring flow control of policy expressions
US8490148B2 (en) 2007-03-12 2013-07-16 Citrix Systems, Inc Systems and methods for managing application security profiles
US8631147B2 (en) 2007-03-12 2014-01-14 Citrix Systems, Inc. Systems and methods for configuring policy bank invocations
US7865589B2 (en) 2007-03-12 2011-01-04 Citrix Systems, Inc. Systems and methods for providing structured policy expressions to represent unstructured data in a network appliance
US8171483B2 (en) 2007-10-20 2012-05-01 Citrix Systems, Inc. Method and system for communicating between isolation environments
US8090797B2 (en) 2009-05-02 2012-01-03 Citrix Systems, Inc. Methods and systems for launching applications into existing isolation environments
WO2012043899A1 (en) * 2010-09-29 2012-04-05 정보통신산업진흥원 Vehicle-specific application store service system and method thereof
CN101980203A (en) * 2010-10-29 2011-02-23 中国科学院声学研究所 Embedded file system for high-definition media
US8533275B2 (en) 2011-08-19 2013-09-10 Microsoft Corporation Synchronizing conversation structures in web-based email systems
CN103124308B (en) * 2011-11-21 2015-09-30 比亚迪股份有限公司 A kind of method, system and mobile terminal running application
JP5891900B2 (en) 2012-03-29 2016-03-23 富士通株式会社 Access control method, server device, and storage device
CN103440303A (en) * 2013-08-21 2013-12-11 曙光信息产业股份有限公司 Heterogeneous cloud storage system and data processing method thereof
CN103984540A (en) * 2014-04-14 2014-08-13 美的集团股份有限公司 Method and device for generating hardware interface running program
US9356913B2 (en) * 2014-06-30 2016-05-31 Microsoft Technology Licensing, Llc Authorization of joining of transformation chain instances
SG10201507051WA (en) * 2015-09-03 2017-04-27 Certis Cisco Security Pte Ltd System and method for high frequency heuristic data acquisition and analytics of information security events
CN106156353B (en) * 2016-07-26 2019-08-09 北京北森云计算股份有限公司 A kind of method and system increasing multilingual on-the-flier compiler enforcement engine for database
US10372945B2 (en) * 2017-01-24 2019-08-06 Microsoft Technology Licensing, Llc Cross-platform enclave identity
CN108108429B (en) * 2017-12-01 2020-08-18 深圳市小牛在线互联网信息咨询有限公司 Data storage method and device of terminal equipment, storage medium and computer equipment
CN110045997B (en) * 2019-04-15 2022-07-05 武汉斗鱼鱼乐网络科技有限公司 Object initialization method, device, equipment and storage medium of basic function module
CN112860645A (en) * 2021-02-09 2021-05-28 恒安嘉新(北京)科技股份公司 Processing method and device for offline compressed file, computer equipment and medium
CN113626835B (en) * 2021-06-25 2022-06-17 荣耀终端有限公司 Data access method and electronic equipment
CN116860905B (en) * 2023-09-04 2023-12-08 青岛市勘察测绘研究院 Space unit coding generation method of city information model

Family Cites Families (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5694597A (en) * 1994-04-26 1997-12-02 International Business Machines Corporation Method and system for optimizing access to a datastore
US6078925A (en) * 1995-05-01 2000-06-20 International Business Machines Corporation Computer program product for database relational extenders
US5991536A (en) * 1996-11-12 1999-11-23 International Business Machines Corporation Object-oriented tool for registering objects for observation and causing notifications to be made in the event changes are made to an object which is being observed
FR2780178B1 (en) * 1998-06-18 2001-08-10 Inst Nat Rech Inf Automat METHOD FOR TRANSFORMING AND TRANSPORTING DATA BETWEEN AGENT SERVERS PRESENT ON MACHINES AND A CENTRAL AGENT SERVER PRESENT ON ANOTHER MACHINE
US6199195B1 (en) * 1999-07-08 2001-03-06 Science Application International Corporation Automatically generated objects within extensible object frameworks and links to enterprise resources
EP1297459A2 (en) 2000-07-03 2003-04-02 Oculus Technologies Corporation Access control for a decentralized or emergent model on a computer network
US6513100B1 (en) * 2000-10-30 2003-01-28 Microsoft Corporation System and method for fast referencing a reference counted item
US6999956B2 (en) * 2000-11-16 2006-02-14 Ward Mullins Dynamic object-driven database manipulation and mapping system
US6957230B2 (en) * 2000-11-30 2005-10-18 Microsoft Corporation Dynamically generating multiple hierarchies of inter-object relationships based on object attribute values
US7178100B2 (en) * 2000-12-15 2007-02-13 Call Charles G Methods and apparatus for storing and manipulating variable length and fixed length data elements as a sequence of fixed length integers
US6697818B2 (en) * 2001-06-14 2004-02-24 International Business Machines Corporation Methods and apparatus for constructing and implementing a universal extension module for processing objects in a database
KR100380996B1 (en) 2001-06-20 2003-04-23 한국전자통신연구원 system for maintaining object consistency and for implementating distributed shared memory in Java and its method

Also Published As

Publication number Publication date
MXPA06001984A (en) 2006-05-17
JP2007521533A (en) 2007-08-02
EP1646954A1 (en) 2006-04-19
AU2003259961B2 (en) 2010-05-27
BR0318464A (en) 2006-09-12
WO2005029363A1 (en) 2005-03-31
CA2532909A1 (en) 2005-03-31
CN1820266A (en) 2006-08-16
KR100959473B1 (en) 2010-05-25
EP1646954A4 (en) 2008-06-11
KR20060080581A (en) 2006-07-10
AU2003259961A1 (en) 2005-04-11

Similar Documents

Publication Publication Date Title
CN100550010C (en) Be used for application program and system and method based on the storage platform interface of item
CN100570549C (en) The system and method that is used for the data modeling of project-based storage platform
CN100458732C (en) Systems and methods for providing relational and hierarchical synchronization services for units of information manageable by a hardware/software interface system
CN1739107B (en) Systems and methods for providing synchronization services for units of information manageable by a hardware/software interface system
JP4583376B2 (en) System and method for realizing a synchronous processing service for a unit of information manageable by a hardware / software interface system
CN101416153B (en) Systems and methods for the implementation of a digital images schema for organizing units of information manageable by a hardware/software interface system
US20050055354A1 (en) Systems and methods for representing units of information manageable by a hardware/software interface system but independent of physical representation
MXPA06001208A (en) Platform for data services across disparate application frameworks.
CN100565505C (en) System and method by intermediary&#39;s file system or device synchronization computer system
CN1739093B (en) Systems for the implementation of a synchronization schemas
CN1871598B (en) Systems and methods for extensions and inheritance for units of information manageable by a hardware/software interface system
CN1716247B (en) System and method for synchronously providing conflict processing for information managing unit by hardware/software interface system
JP4394644B2 (en) Storage platform for organizing, searching, and sharing data
RU2371757C2 (en) Systems and methods of data modelling in storage platform based on subjects
RU2412461C2 (en) Systems and methods of interfacing application programs with article based storage platform
KR101109390B1 (en) Systems and methods for providing synchronization services for units of information manageable by a hardware/software interface system
ZA200600645B (en) Systems and methods for data modeling in an item-based storage platform

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant
ASS Succession or assignment of patent right

Owner name: MICROSOFT TECHNOLOGY LICENSING LLC

Free format text: FORMER OWNER: MICROSOFT CORP.

Effective date: 20150507

C41 Transfer of patent application or patent right or utility model
TR01 Transfer of patent right

Effective date of registration: 20150507

Address after: Washington State

Patentee after: Micro soft technique license Co., Ltd

Address before: Washington State

Patentee before: Microsoft Corp.

CF01 Termination of patent right due to non-payment of annual fee
CF01 Termination of patent right due to non-payment of annual fee

Granted publication date: 20091014

Termination date: 20200821