ArticleslgStudy

computer science

LCHH architecture

LCHH architecture is a computer science topic covered in the lgStudy science library. This page brings together a partial reference excerpt, illustrations, worked examples, real-world applications and a short study plan, so you can understand LCHH architecture rather than just read about it. In short: The Loader–Content–Handler–Handler (LCHH) is a web programming architecture that is closely modeled after the HTTP request-response cycle and the 3-tier web structure. As its name suggests, LCHH defines four key implementation components: The Loader is an ID'ed DIV container that identifies a partial update region for later content injection; The Content that contains both static information and interactive elements…

LCHH architecture — main illustration
LCHH architecture — illustration

Key takeaways

  • LCHH architecture belongs to computer science; place it in that map before memorising details.
  • Learn the definition first, then one example that makes the definition concrete.
  • Connect LCHH architecture to a quantity you can measure, compute or draw — that is where exam questions come from.
  • Reproduce the core statement of LCHH architecture from memory before moving on to harder problems.

Reference excerpt

The Loader–Content–Handler–Handler (LCHH) is a web programming architecture that is closely modeled after the HTTP request-response cycle and the 3-tier web structure. As its name suggests, LCHH defines four key implementation components:

The Loader is an ID'ed DIV container that identifies a partial update region for later content injection; The Content that contains both static information and interactive elements, also known as "Triggers"; Client-side Handlers that process various trigger events, such as button clicks; Server-side Handlers that respond to Ajax requests that are sent by the client-side handlers. Server-side handlers typically perform database CRUD operations before piggy-backing the updated content into the aforementioned Loader.

Comparison with XHR injection LCHH uses the responseText of an XMLHttpRequest to replace the innerHTML value of the target DIV container. This is a common Ajax pattern. XHR injection alone, however, does not sum up LCHH. The "Content" in the initial loading of LCHH is instantly generated on the server-side as opposed to loading an empty container and then populating the container with another Ajax round-trip. Piggy-backing renewed content after database changes is also characteristic of LCHH. LCHH organizes code into four categories:

Loader and client-side Handlers (JavaScript functions) are stored in a "user-facing" file that is directly accessible by its URL; A server-side script that can be included by the user-facing file. This script outputs the "Content"; A "routing script" that serves as a single point of call for invoking various Ajax calls; Server-side handlers, typically stored under an "include" or "icl" sub-directory. Each handler is often implemented in a separate script file.

Example

References "LCHH vs. MVC". October 10, 2013. Retrieved April 28, 2016. Dong, Schien (2015), There is No AJAX - The Art of Blending DHTML, PHP and MySQL (7th ed.), Lulu Press, Incorporated, pp. 338–343, ISBN 978-1435774810

Illustrations

LCHH architecture: Example Flow and File Organization of the LCHH Architecture
Example Flow and File Organization of the LCHH Architecture

Worked examples

Example 1 — a first encounter with LCHH architecture

Start with the simplest possible case. Write down what LCHH architecture claims or describes in one sentence, then invent the smallest concrete situation in which that sentence is true. In computer science, the smallest case is usually a single object, a single equation or a single measurement. Check that every symbol or term in your sentence has a meaning in that case.

Example 2 — changing one variable

Take the situation from Example 1 and change exactly one quantity: double it, halve it, or set it to zero. Predict what should happen to LCHH architecture before you calculate. Comparing your prediction with the result is the fastest way to find out whether you understand the idea or only the words.

Example 3 — an exam-style question

Typical questions about LCHH architecture ask you to (a) state it precisely, (b) apply it to given data, and (c) explain a limitation. Practise writing all three answers in under five minutes; the third part is what separates a full-mark answer from an average one.

Applications of LCHH architecture

In research
LCHH architecture appears in computer science research whenever the underlying quantities have to be modelled precisely. Papers usually cite it as a starting assumption and then explore where it breaks down.
In technology and industry
Engineering practice reuses LCHH architecture in design rules, simulations and safety margins. Knowing the idea lets you read a specification sheet and understand why the numbers look the way they do.
In the classroom
LCHH architecture is common in secondary-school and first-year university syllabi. It links to neighbouring topics Architectural pattern (computer science), Software design patterns, so understanding it makes those chapters shorter.
In everyday life
Look for LCHH architecture outside the textbook — in sport, cooking, traffic, electronics or the sky above you. An example you found yourself is remembered far longer than one you were given.
Ask Teacher Smith questions about this articleOpens your AI tutor with a question about “LCHH architecture” →

How to study LCHH architecture in 20 minutes

  1. Read the reference excerpt below once, without taking notes.
  2. Close the page and write down what LCHH architecture means in your own words.
  3. Compare your version with the excerpt and mark what you missed.
  4. Work through the three examples above with pen and paper.
  5. Explain LCHH architecture out loud to somebody else — or to Teacher Smith in the lgStudy chat.

Frequently asked questions

What is LCHH architecture in simple terms?

The Loader–Content–Handler–Handler (LCHH) is a web programming architecture that is closely modeled after the HTTP request-response cycle and the 3-tier web structure. As its name suggests, LCHH defines four key implementation components: The Loader is an ID'ed DIV container that identifies a parti…

Why does LCHH architecture matter?

Because it connects several computer science ideas at once: it gives you a definition you can apply, a quantity you can calculate, and a way to check whether a result is plausible.

How should I study LCHH architecture?

Read the excerpt, restate it from memory, then work through the examples and applications listed on this page. The five-step study plan above takes about twenty minutes.

What does this page cover?

It gives you a compact reference excerpt plus original lgStudy explanations, examples, applications and study material on LCHH architecture.

Tags

  • Architectural pattern (computer science)
  • Software design patterns

Keep exploring