The present invention relates to the electrical, electronic and computer arts, and, more particularly, to user interfaces and the like.
User interfaces (UIs) address presentation of content, and interaction with respect to such content, for the user consuming the UI. Initially, UIs were tightly coupled, allowing minimum reuse of either content or presentation. However, the “model view controller” (MVC) architecture has allowed decoupling of presentation from the actual content, with the model being the interface between the two. At run-time, content can be obtained from various sources, and then embedded in the presentation or layout, to render it via the model. Even though it brings some loose coupling, the MVC pattern needs to be encoded in a single program, and the presentation, content and interactions are part of the same application.
Principles of the invention provide techniques for providing a user interface as a service. In one aspect, an exemplary method (which can be computer-implemented) includes the steps of determining, with a user interface service composer, based on a user interface request from a user interface consumer, one of a plurality of user interface service providers to be invoked; and consulting, by the user interface service composer, a particular entry in a user interface data catalog having a plurality of entries for the plurality of user interface service providers. The particular entry corresponds to that given one of the plurality of user interface service providers that is to be invoked. An additional step includes routing, from the user interface service composer to the given one of the plurality of user interface service providers that is to be invoked, a request message for rendering a user interface requested in the user interface request received from the user interface consumer. The request message includes configuration parameters and interaction-related data, and is formatted in accordance with the particular entry in the user interface data catalog. Further steps include receiving, by the user interface service composer from the given one of the plurality of user interface service providers that is to be invoked, the user interface requested in the user interface request received from the user interface consumer; and forwarding, by the user interface service composer to the user interface consumer, the user interface requested in the user interface request received from the user interface consumer.
One or more embodiments of the invention or elements thereof can be implemented in the form of a computer product including a tangible computer usable storage medium with computer usable program code for performing the method steps indicated. Furthermore, one or more embodiments of the invention or elements thereof can be implemented in the form of an apparatus including a memory and at least one processor that is coupled to the memory and operative to perform exemplary method steps. Yet further, in another aspect, one or more embodiments of the invention or elements thereof can be implemented in the form of means for carrying out one or more of the method steps described herein; the means can include (i) hardware module(s), (ii) software module(s), or (ii) a combination of hardware and software modules; any of (i)-(iii) implement the specific algorithms set forth herein.
One or more embodiments of the invention may offer one or more of the following technical benefits: loose coupling of user interface and content, the same content and interaction can be rendered using different UI Service Providers, and the service providers can be dynamically chosen based on context (such as end-clients with difference in display and with different style requirements).
These and other features, aspects and advantages of the present invention will become apparent from the following detailed description of illustrative embodiments thereof, which is to be read in connection with the accompanying drawings.
As noted, even though it brings some loose coupling, the MVC pattern needs to be encoded in a single program, and the presentation, content and interactions are part of the same application. In one or more embodiments of the invention, there is support to dynamically choose or change the presentation based on factors such as availability of a better UI rendering available somewhere, user preferences, device type, UI technology type, and so on. The loose coupling of the prior art was in effect addressing only the techniques by which the data was obtained, while the logic of the presentation was still not configurable, or was pre-designed and implemented, and not determined at runtime. In contrast, one or more instances of the invention may provide the presentation user interface as a service, which can be invoked by any other application to render and interact with such other application's content. The service exposes an interface, via which the consumer can provide details on the content and expected interaction, alongside some configuration parameters, which allow for limited change to the actual presentation style.
Aspects of the invention provide a method and apparatus to expose and use a UI as a configurable and re-usable service, and permit visualizing the presentation tier as a configurable third party service, which, when invoked with the right semantics (content, configuration and interaction) displays the data, and allows interaction with it, in the predefined format. In some instances, a UI Service Composer invokes content services to get content to be displayed on the interface and to post back user entered data to corresponding services to save.
With reference now to
UI Service Composer 202 handles all communication with the end-user 210 who is consuming the user interface. In one or more embodiments, composer 202 handles requests through all possible channels and then appropriately renders the user interface, coordinating with Content Services 204 and UI Service Providers 206.
With regard to UI Service Providers, block 206 can include a list of UI Rendering services which render a User Interface, given some content and control parameters. UI Service Providers 206 can vary, for example:
Each UI Service Provider 206 has a way of mapping the content to the User layout they provide, and prescribes semantics by which the content needs to be annotated when sent to them, which will enable them to pick up the right UI Elements and UI Layout to render the same. Each UI Service Provider, in addition to rendering the User Interface, will also be able to extract information from a UI it rendered, in terms of user entered data, input mappings to a particular interaction point on the user interface, and the like.
The Catalog 208 helps with regard to detail capturing of the meta-information associated with each UI Service Provider 206. The catalog is populated with a list of UI service Providers and their Meta-information, listed, in accordance with one or more embodiments of the invention, as UI Service Description Language (USDL). The USDL will list one or more of the following:
This approach helps in “plug and play” of any UI Service Provider, such that same can be available in this framework for rendering the User Interface.
Aspects of the invention assist in listing UI Service Providers (by way of example and not limitation, Google Maps, http://maps.google.com/) in a Catalog, adding more annotation or meta-information about the services. The UI Service Composer then can lookup the details of the Service Provider and invoke the service provider with appropriate content fetched from content services (by way of example and not limitation, content services include Google and Amazon (http://www.amazon.com/gp/browse.html?node=3435361)).
Furthermore, aspects of the invention adhere to the MVC pattern, but further provide run time dynamism between the Mode—View and Controller, by allowing plug and play of various Content and UI Service Providers. In addition, embodiments of the invention address services oriented architecture (SOA) principles in exposing each UI Rendering component as a UI Service Provider; such providers making themselves discoverable by cataloging their information. The UI Service Composer, at run time, chooses a particular UI Service Provider, passing the content to be displayed as a request message in the semantics understood by the UI Service provider. Aspects of the invention can be applied to any presentation layer of any application, and are not restricted to any specific pattern or type of User Interface.
One or more embodiments of the invention provide a system and method for providing UIs as an external, consumable service. The architecture includes a UI composer which takes the place of the server in the traditional model, a catalog where UI services can be registered and queried for, and a service provider which provides the UI service. In at least some instances, the data to be rendered (that is, content) on the UI is provided as part of the request message to the service, and/or input from the user on the user interface is sent back to the service composer, which can then do the necessary steps of persisting and/or modifying it.
Furthermore, one or more embodiments of the invention provide a system which allows limited re-configuration of a rendered UI at runtime, based on certain request parameters, and/or a system and method where the expected interaction with the UI is mapped to an interaction point on screen (for example, a button click) as provided by the UI service in the request message. Yet further, at least some instances of the invention provide a system and method where the UI service sends back data and control to the service consumer in response to user action based on interaction logic specified in the request; a system and method where the UI service is registered in a catalog with its expected request and response format as well as meta-data which includes a screenshot of what the generated UI looks like; and/or a system and method where the traditional application providers act as UI service composers and invoke the correct UI service providers to get the presentation and route to the end consumer (in at least some instances, they also get back the data from the end consumer and route it back to the service provider).
Attention should now be had to
This request can be the same as what is sent to the server 104 in a traditional client server application. Depending on the request, the service composer 202 identifies whether the UI, or parts of it, need to be rendered via a UI service provider 206. If so, composer 202 composes the appropriate message 236 and routes it to the service provider 206 (in one or more embodiments, the second step identified below is carried out prior to this routing, so that the message 236 has the proper semantics). The request message may include one or more, and preferably all, of the following:
In a second step, the Composer 202 queries the UI Service Catalog 208, to obtain the details of the UI Service Provider 206 in terms of the input message and output message format, the possible configuration parameters it can set, and the like. It then converts the content that it has to the semantics of the UI Service Provider 206, and invokes the UI Service Provider 206 with the converted content 236.
In a third step, UI Service Provider 206, upon receiving the request 236, queries its internal configuration repository on information such as, UI elements to Content Type bindings, UI Layouts and input/output mappings to interaction points on the User Interface. Using this information, it then renders the final User Interface 238 appropriately back to the UI Service Composer 202.
In a fourth step, the UI Service composer 202 then forwards the final User Interface to the end user 210 through the appropriate channel. In a fifth step, the user 210 invokes an interaction point on the UI (such as filling something in on the UI, and clicks the appropriate button). The response is routed back to the provider 206 via the service composer 202 (which acts as a router), as indicated at 242. The UI Page is sent to the provider, who extracts the user entered data and sends it back to the UI Service provider.
In a sixth step, the service provider 206 decomposes the data received from the client 210 and forwards the appropriate fields 240 (user entered data) back to the service composer 202. Exactly what provider 206 forwards back is dependant on the interaction-related data specified in the original request 236. In a seventh step, the service composer 202 gets back (i) data on what interaction point has been invoked and (ii) other appropriate data. Composer 202 can then appropriately process the data and forward the client 210 to a new target (i.e. UI).
Note that interaction between elements 202, 206, 208 can make use of the aforesaid USDL.
It will be appreciated that
From the above information, Service Composer 202 will be able to know what UI Service Provider 206 to contact, in order to get the Login Page rendered.
In a second step performed by composer 202, the composer 202 then queries the UI Service Catalog 208 and uses the information to appropriately transform the content and send it as a request to the UI Service Provider 206, as at 236.
The User Interface rendered will have layout of a Login page with UI elements “username” and “password,” and the login button ( interaction point) associated with the content mapping (username and password as inputs). In a fourth step performed by composer 202, upon receiving the User Interface from the UI Service Provider 206, the composer 202 then forwards this User Interface to the appropriate end consumer 210.
A non-limiting exemplary loading of a home page will be described as another illustrative use case. End user 210 has entered the user name and password information and has pressed the “login” button (interaction point) as per
In a third step of this example, the composer 202 then invokes the appropriate content service 204 associated with the interaction point, to validate the Login. Upon successful login, the Service Composer 202 understands that it needs to render the Home Page associated with this login (for example, by implementation logic or referred from configuration). Composer 202 also determines the content services that will render the content for the Home Page and the associated content service(s) 204 on this Home Page that is/are required for posting the data. Composer 202 then invokes the Content services 204 to fetch the content (see content request 260 and response 262). As seen in
In a fourth step of this example, UI Composer 202 then queries the UI Service Catalog 208 and gets the details of the particular UI Service Provider 206 that needs to be invoked to render the User Interface for the Home Page. Composer 202 then appropriately transforms the content fetched from the content service 204 to the semantics understood by the UI Service Provider, and sends same to the UI Service Provider 206, as at 236.
In a fifth step of this example, the UI Service Provider 206, using its meta-information, renders the User Interface, with content, back to the UI Service Composer, as at 238. In a sixth step of this example, upon receiving the User Interface from the UI Service Provider 206, the composer 202 then forwards this User Interface to the appropriate end consumer 210.
In another aspect, with reference to
In yet another aspect, with reference to
In view of the preceding, it will be appreciated that, in general terms, an exemplary method 1400 (as shown in
Step 1410 includes consulting, by the user interface service composer, a particular entry in a user interface data catalog 208 having a plurality of entries for the plurality of user interface service providers 206. The particular entry corresponds to that given one of the plurality of user interface service providers 206 that is to be invoked. Step 1412 includes routing, from the user interface service composer 202 to the given one of the plurality of user interface service providers 206 that is to be invoked, a request message for rendering a user interface requested in the user interface request received from the user interface consumer. The request message includes at least configuration parameters and interaction-related data, and is formatted in accordance with the particular entry in the user interface data catalog 208.
Step 1414 includes the user interface service composer 202 receiving the requested user interface from the from the given one of the plurality of user interface service providers 206. Step 1416 includes forwarding, by the user interface service composer 202 to the user interface consumer 210, the requested user interface.
Optional step 1406 includes determining, with the user interface service composer 202, based on the user interface request from the user interface consumer 210, one of a plurality of content service providers 204 to be invoked. Optional step 1408 includes fetching, by the user interface service composer 202, from the one of the plurality of content service providers 206 to be invoked, the content to be rendered. In this example, in the routing step 1412, the request message further includes the content to be rendered, and the user interface includes the content to be rendered.
In some cases, an input is obtained from the user interface consumer, by the user interface service composer; for example, as an invocation of an interaction point on the user interface. As per decision block 1418 (YES branch), when this occurs, user interface service composer 202 routes the input to user interface service provider 206, essentially repeating step 1412 (and as needed, any intervening steps 1404-1410). User interface service provider 206 decomposes the input from the user interface consumer, to obtain decomposed data, and forwards same to user interface service composer 202, in an analog of step 1414. Composer 202 processes the data to obtain a new user interface and forwards same to the user interface consumer 210, in an analog of step 1416. In a non-limiting example, the user interface is a login page and the new user interface is a home page.
In some instances, a UI to be rendered, such as the aforementioned login page, does not require content service access, while another UI to be rendered (for example, the new UI, such as the aforementioned home page) does require content service access. In such a case, (repeated) step 1404 includes determining, with the user interface service composer 202, based on the input from the user interface consumer, one of a plurality of content service providers 204 to be invoked. Composer 202 fetches, from the one of the plurality of content service providers to be invoked, the content to be rendered, as per 1408. In step 1412, a specification of the content to be rendered is also routed; and the home page includes the content to be rendered.
When no further input is received, processing continues at block 1420, per the NO branch of block 1418.
As described with regard to
As described with regard to
A variety of techniques, utilizing dedicated hardware, general purpose processors, firmware, software, or a combination of the foregoing may be employed to implement the present invention or components thereof. One or more embodiments of the invention, or elements thereof, can be implemented in the form of a computer product including a computer usable medium with computer usable program code for performing the method steps indicated. Furthermore, one or more embodiments of the invention, or elements thereof, can be implemented in the form of an apparatus including a memory and at least one processor that is coupled to the memory and operative to perform exemplary method steps.
One or more embodiments can make use of software running on a general purpose computer or workstation. With reference to
Accordingly, computer software including instructions or code for performing the methodologies of the invention, as described herein, may be stored in one or more of the associated memory devices (for example, ROM, fixed or removable memory) and, when ready to be utilized, loaded in part or in whole (for example, into RAM) and executed by a CPU. Such software could include, but is not limited to, firmware, resident software, microcode, and the like.
Furthermore, the invention can take the form of a computer program product accessible from a computer-usable or computer-readable medium (for example, media 1518) providing program code for use by or in connection with a computer or any instruction execution system. For the purposes of this description, a computer usable or computer readable medium can be any apparatus for use by or in connection with the instruction execution system, apparatus, or device. The medium can store program code to execute one or more method steps set forth herein.
The medium can be an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system (or apparatus or device) or a propagation medium. Examples of a tangible computer-readable storage medium include a semiconductor or solid-state memory (for example memory 1504), magnetic tape, a removable computer diskette (for example media 1518), a random access memory (RAM), a read-only memory (ROM), a rigid magnetic disk and an optical disk. Current examples of optical disks include compact disk-read only memory (CD-ROM), compact disk-read/write (CD-R/W) and DVD.
A data processing system suitable for storing and/or executing program code will include at least one processor 1502 coupled directly or indirectly to memory elements 1504 through a system bus 1510. The memory elements can include local memory employed during actual execution of the program code, bulk storage, and cache memories which provide temporary storage of at least some program code in order to reduce the number of times code must be retrieved from bulk storage during execution.
Input/output or I/O devices (including but not limited to keyboards 1508, displays 1506, pointing devices, and the like) can be coupled to the system either directly (such as via bus 1510) or through intervening I/O controllers (omitted for clarity).
Network adapters such as network interface 1514 may also be coupled to the system to enable the data processing system to become coupled to other data processing systems or remote printers or storage devices through intervening private or public networks. Modems, cable modem and Ethernet cards are just a few of the currently available types of network adapters.
Computer program code for carrying out operations of the present invention may be written in any combination of one or more programming languages, including an object oriented programming language such as Java, Smalltalk, C++ or the like and conventional procedural programming languages, such as the “C” programming language or similar programming languages. The program code may execute entirely on the user's computer, partly on the user's computer, as a stand-alone software package, partly on the user's computer and partly on a remote computer or entirely on the remote computer or server. In the latter scenario, the remote computer may be connected to the user's computer through any type of network, including a local area network (LAN) or a wide area network (WAN), or the connection may be made to an external computer (for example, through the Internet using an Internet Service Provider).
Embodiments of the invention have been described herein with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems) and computer program products. It will be understood that each block of the flowchart illustrations and/or block diagrams, and combinations of blocks in the flowchart illustrations and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions/acts specified in the flowchart and/or block diagram block or blocks.
These computer program instructions may also be stored in a tangible computer-readable storage medium that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable medium produce an article of manufacture including instruction means which implement the function/act specified in the flowchart and/or block diagram block or blocks. The computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide processes for implementing the functions/acts specified in the flowchart and/or block diagram block or blocks.
The flowchart and block diagrams in the figures illustrate the architecture, functionality, and operation of possible implementations of systems, methods and computer program products according to various embodiments of the present invention. In this regard, each block in the flowchart or block diagrams may represent a module, segment, or portion of code, which comprises one or more executable instructions for implementing the specified logical function(s). It should also be noted that, in some alternative implementations, the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or the blocks may sometimes be executed in the reverse order, depending upon the functionality involved. It will also be noted that each block of the block diagrams and/or flowchart illustration, and combinations of blocks in the block diagrams and/or flowchart illustration, can be implemented by special purpose hardware-based systems that perform the specified functions or acts, or combinations of special purpose hardware and computer instructions.
In any case, it should be understood that the components illustrated herein may be implemented in various forms of hardware, software, or combinations thereof; for example, application specific integrated circuit(s) (ASICS), functional circuitry, one or more appropriately programmed general purpose digital computers with associated memory, and the like. Given the teachings of the invention provided herein, one of ordinary skill in the related art will be able to contemplate other implementations of the components of the invention.
It will be appreciated and should be understood that the exemplary embodiments of the invention described above can be implemented in a number of different fashions. Given the teachings of the invention provided herein, one of ordinary skill in the related art will be able to contemplate other implementations of the invention. Indeed, although illustrative embodiments of the present invention have been described herein with reference to the accompanying drawings, it is to be understood that the invention is not limited to those precise embodiments, and that various other changes and modifications may be made by one skilled in the art without departing from the scope or spirit of the invention.