IP Library Patent Application 12243495
Patent Application
App. No. 12/243,495

Runtime Object Composition

Loading inventors, assignments & file history…
Monitor This Case
Get email alerts when status or documents change.
Order Certified Copies
Most orders are placed with the USPTO same day — all within 24 business hours.
Order via The Patent Place →
Pre-filled with this patent's details
Quick Facts
Patent No.
US None
App. No.
12/243,495
Abstract

Objects in computing environments are often instantiated based on a class definition that is statically declared at design time, but such instantiation limits the flexibility of the objects so created. Objects may also be composed at runtime through a series of invocations of a reflection programming interface, but reflection techniques may be computationally expensive, and the generation of many objects at runtime based on a single object definition may redundantly invoke the reflection programming interface. As provided herein, when requested to generate a new object at runtime based on an object definition, the host environment may instead automatically generate a factory method (via reflection) using the object definition, and may invoke the factory method to compose the object. The factory method may also be cached with the object definition to facilitate the composing of additional objects based on the same object definition, thereby economizing computing resources and improving system performance.

Claims (79)

1 . A computer-implemented method of composing an object at runtime according to an object definition, the method comprising:

generating a factory method configured to compose the object according to the object definition, and

invoking the factory method to compose the object.

2 . The method of claim 1 :

the object definition specified in an application managed by a runtime component, and

the method invoked at runtime by the runtime component.

3 . The method of claim 1 , the object definition specifying at least one of:

at least one constant,

at least one primitive data type,

at least one constructor method,

at least one invokable method,

at least one interface, and

at least one event.

4 . The method of claim 1 :

the object definition including at least one constructor method, and

the factory method configured to invoke the constructor method.

5 . The method of claim 1 :

the object definition specifying a base class from which the object is derived, and

the factory method configured to:

compose an instance of the base class, and

supplement the instance of the base class according to the object definition.

6 . The method of claim 1 :

the object definition specifying at least one contained object, and

the factory method configured to:

compose the at least one contained object, and

add the at least one contained object to the object.

7 . The method of claim 1 :

the object definition comprising at least one event handler method of the object to handle at least one event, and

the factory method configured, after invoking the factory method to compose the object, to subscribe the at least one event handler method to the at least one event.

8 . The method of claim 1 , the generating comprising:

generating a source code module comprising a factory method configured to compose the object according to the object definition, and

invoking a compiler to at least partially compile the source code module.

9 . The method of claim 1 , the generating comprising: emitting at least one at least partially compiled instruction configured to compose the object according to the object definition.

10 . The method of claim 1 :

the method comprising: upon generating the factory method, storing the object definition associated with the factory method in a factory method cache; and

the generating comprising:

searching the factory method cache for a cached object definition matching the object definition; and

upon finding a cached object definition matching the object definition in the factory method cache, retrieving from the factory method cache the factory method associated with the cached object definition.

11 . A system configured to composing an object at runtime according to an object definition, the system comprising:

a factory method generating component configured to generate a factory method configured to compose the object according to the object definition, and

a factory method invoking component configured to invoke the factory method to compose the object.

12 . The system of claim 11 :

the object definition specified in an application managed by a runtime component, and

the runtime component comprising the factory method generating component and the factory method configuring component.

13 . The system of claim 11 :

the object definition specifying at least one constructor method, and

the factory method generating component configured to generate a factory method configured to invoke the constructor method.

14 . The system of claim 11 :

the object definition specifying a base class from which the object is derived, and

the factory method generating component configured to generate a factory method configured to:

compose an instance of the base class, and

supplement the instance of the base class according to the object definition.

15 . The system of claim 1 1 :

the object definition specifying at least one contained object, and

the factory method generating component configured to generate a factory method configured to:

compose the at least one contained object, and

add the at least one contained object to the object.

16 . The system of claim 11 :

the object definition comprising at least one event handler method of the object to handle at least one event, and

the factory method generating component configured to generate a factory method configured to subscribe the at least one event handler method to the at least one event.

17 . The system of claim 11 , the factory method generating component configured to

generate a source code module comprising a factory method configured to compose the object according to the object definition, and

invoke a compiler to at least partially compile the source code module.

18 . The system of claim 11 , the factory method generating component configured to emit at least one at least partially compiled instruction configured to compose the object according to the object definition.

19 . The system of claim 11 :

the system comprising:

a factory method cache configured to store an object definition associated with a factory method, and

a factory method caching component configured to store the object definition in the factory method cache with the factory method; and

the factory method generating component configured to:

search the factory method cache for a cached object definition matching the object definition; and

upon finding a cached object definition matching the object definition in the factory method cache, retrieve from the factory method: cache the factory method associated with the cached object definition.

20 . A computer-implemented method invoked at runtime by a runtime component to compose an object according to an object definition specified in an application managed by the runtime component, the runtime component further comprising a factory method cache configured to store an object definition associated with a factory method, and the method comprising:

searching the factory method cache for a cached object definition matching the object definition;

upon finding a cached object definition matching the object definition in the factory method cache, retrieving from the factory method cache the factory method associated with the cached object definition;

upon failing to find a cached object definition matching the object definition in the factory method cache:

generating a factory method comprising a set of at least partially compiled instructions configured to compose the object according to the object definition, and

storing the object definition with the factory method in a factory method cache;

invoking the factory method to compose the object; and

subscribing at least zero event handler methods of the object to at least zero events according to the object definition.

Assignments (2)
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Jan 15, 2015
From: MICROSOFT CORPORATION
To: MICROSOFT TECHNOLOGY LICENSING, LLC
Reel/Frame 034766/0509 →
ASSIGNMENT OF ASSIGNOR'S INTEREST Recorded Oct 27, 2008
From: TAVARES, CHRISTOPHER; PULEIO, MICHAEL
To: MICROSOFT CORPORATION
Reel/Frame 021738/0962 →