Tagged articles
callbacks
23 articles · Page 1 of 1
This article explains why LLMs need memory, compares BufferMemory and ConversationSummaryBufferMemory, demonstrates how to build memory‑aware chains with LangChain Expression Language (LCEL), and shows practical examples including translation, RAG, and callbacks for monitoring chain execution.
ChainLCELLLM
0 likes · 12 min read

The article explains how Java inner classes can be used to encapsulate related functionality, access private members of the outer class, implement interfaces for callbacks, and hide implementation details, providing clear code examples such as Car/Engine, Counter/Incrementer, Button listeners, and a Calculator with an Operation inner class.
EncapsulationInner ClassesJava
0 likes · 4 min read

This tutorial explains what function pointers are, how to declare and use them in C, and demonstrates practical embedded‑system patterns such as callbacks, state machines, command dispatch, and advanced techniques like pointer arrays and struct members, while highlighting common pitfalls.
C++Embeddedcallbacks
0 likes · 13 min read

LangChain’s callback system lets developers hook into every stage of an LLM chain— from chain start/end to token generation—using built‑in handlers like StdOutCallbackHandler or custom handlers derived from BaseCallbackHandler, with examples showing constructor‑level and request‑level attachment, plus a custom handler implementation.
AIDebuggingLLM
0 likes · 6 min read

The article explains how early thread‑blocking models led to the invention of callbacks, why deeply nested callbacks create "callback hell," and how promises/futures and their chaining, as well as coroutines, provide more linear and efficient asynchronous programming for high‑concurrency backend services.
Asynchronous ProgrammingPromisescallback hell
0 likes · 6 min read

This article explores the concept of functions from their mathematical definition through programming language implementation, detailing key elements, stack-based execution mechanics in C, and three perspectives: functions as reusable abstraction units, control flow management tools via call stacks and callbacks, and operators in dataflow architecture pipelines.
call stackcallbacksdataflow architecture
0 likes · 8 min read

The article traces the evolution from blocking thread‑based synchronous code to callback‑driven asynchronous patterns, exposes the pitfalls of callback hell, and shows how promises/futures and their chainable API offer a cleaner, more efficient way to handle high‑concurrency backend operations.
Asynchronous ProgrammingPromisescallbacks
0 likes · 6 min read

Callback functions, once fundamental to asynchronous JavaScript, suffer from deep nesting, poor error handling, and maintenance challenges, prompting developers to adopt modern alternatives like Promises and async/await, which offer clearer flow, unified error management, and better integration with contemporary frameworks.
Async/AwaitJavaScriptPromises
0 likes · 6 min read

The article explains Function Object Programming (FOP) in PHP, outlines its drawbacks, and presents alternative approaches such as anonymous functions, class methods, and closures with code examples, concluding with practical usage scenarios and guidance on choosing the most suitable method.
Anonymous FunctionsFunction ObjectsPHP
0 likes · 4 min read

JavaScript’s single‑threaded nature makes asynchronous programming essential, and this guide explains callbacks, promises (including states and chaining), and async/await syntax with clear examples, illustrating how each technique avoids blocking the main thread and improves code readability and error handling.
Async/AwaitJavaScriptPromises
0 likes · 9 min read

This article explains C function pointers—from basic declaration and typedef usage to calling functions, passing pointers as parameters for callbacks, returning pointers from functions, and creating pointer arrays—illustrated with complete code samples and practical use cases.
C++Code Examplescallbacks
0 likes · 14 min read

This article explains PHP's array_reduce() function, detailing its syntax and parameters, and demonstrates its usage through three examples: summing numbers, concatenating strings, and calculating product, helping beginners understand how to reduce arrays to a single value with callbacks.
PHParray manipulationarray_reduce
0 likes · 4 min read

This comprehensive guide explains what callback functions are, their purposes and common use cases, multiple implementation techniques such as function pointers, functors, and lambda expressions, and provides practical C++ examples, advantages, drawbacks, and best‑practice recommendations.
Asynchronous ProgrammingC++callbacks
0 likes · 16 min read

The article breaks down modern asynchronous programming by examining four core models—callbacks, Promises, reactive observer patterns, and message‑driven architectures—explaining their mechanics, pros and cons, and providing JavaScript/Dart examples and system diagrams to help developers master non‑blocking concurrency.
Async/AwaitAsynchronous ProgrammingConcurrency
0 likes · 26 min read

This article explains that callbacks are essentially function variables, illustrating the concept with plain C code examples, comparing direct function calls to passing functions as parameters, and showing how this approach avoids massive if‑else chains while keeping the logic clear and reusable.
c-programmingcallbacksfunction pointers
0 likes · 3 min read

This article explains what PHP anonymous functions are, shows their concise syntax, demonstrates typical use cases such as callbacks and closures with code examples, and outlines their advantages like brevity, flexibility, and the ability to capture external variables.
callbacks
0 likes · 8 min read

This article explains the fundamentals of C function pointers, how to declare and use them, employ typedef for readability, pass them as arguments, return them from functions, store them in arrays, and apply them to implement flexible callback mechanisms with complete code examples.
C languageC++callbacks
0 likes · 14 min read

This article reviews why asynchronous programming is needed, explains continuations, compares callbacks, promises, reactive streams, async/await, and user‑level threads, and shows how each technique reduces I/O blocking and improves concurrency in Java applications.
Async/AwaitAsynchronous ProgrammingConcurrency
0 likes · 13 min read


ByteFEApr 29, 2021 · Frontend Development
The article explains how using functions that were not intended as callbacks—such as library utilities, Web APIs, or option objects—can break when array.map or other higher‑order functions pass extra arguments, and it shows safer patterns, TypeScript behavior, and linting hints to prevent these bugs.
JavaScriptTypeScriptWeb APIs
0 likes · 12 min read

This article explains PHP anonymous functions (closures), demonstrating how to reference local variables with the use keyword, embed anonymous functions within regular functions, return them, pass parameters, and use them as arguments, accompanied by clear code examples.
Anonymous Functionscallbacksclosures
0 likes · 2 min read

This article walks through the evolution of JavaScript asynchronous patterns—from basic callbacks and their pitfalls, through Promise creation, chaining, and error handling, to the modern async/await syntax—showing how to write clear, maintainable code for real‑world API calls.
Async/AwaitJavaScriptPromises
0 likes · 22 min read

This article walks through classic Node.js callback examples, demonstrates how event emitters can replace tangled callback nesting, and then shows how promises and async/await provide cleaner, more maintainable asynchronous code, encouraging developers to upgrade their Node version.
Async/AwaitJavaScriptNode.js
0 likes · 3 min read


21CTOApr 24, 2016 · Mobile Development
This article explains how most Android code is driven by event callbacks, examines single‑event and multi‑event implementations, discusses the pitfalls of bloated callbacks, and offers practical strategies to structure and simplify callback‑heavy code for clearer, more maintainable apps.
Androidcallbackscode organization
0 likes · 7 min read
