What is ADHOC?
ADHOC is an application for abstracting programming logic away from the syntax of any particular programming language. The idea is that a program contains some important logic that only a “programmer” can supply, but most of the rest is syntactic fluff for helping a text-based compiler understand the important logic. ADHOC supplies a graphical interface and optimization tools in order to let you focus solely on designing the important logic.
How Is It Used?
ADHOC presents you with a tree structure for expressing the logic of a program. The tree resembles a horizontal parse tree of a textual program. For example:
Nodes in the tree can be added from a toolbar, dragged around, selected, updated, re-ordered, and deleted. When the logic tree is completed, you can choose a target language in the control panel, and click the “Generate” button, to generate your program in the chosen language.
Who Is It Meant For?
ADHOC’s primary target audience is professional software developers who work in fast-paced and constantly evolving environments. While software stacks and hot technologies change with the seasons, business logic seldom does, and ADHOC’s philosophy is to focus your efforts on what’s constant.
If you’re not a “programmer”, don’t worry! Ultimately, the goal is for ADHOC to be so straight-forward that anyone can use it to describe the logic that is important to them.
What Are the Benefits?
- Portability: Because ADHOC stores only the program logic, it can be used to generate code in many different languages, and across multiple platforms. If you’re working on a project on a LAMP webserver, but you (or your IT department) decide to move to a Windows server running ASP .NET, you don’t need to rewrite a single line of code! Simply take the ADHOC project file that generated your PHP code, and this time, use it to generate ASP. Write once, implement anywhere.
- Extensibility: ADHOC connects to a database (in the works) of established algorithms, design patterns, and other programming constructs. This lets you quickly include complex logic that someone else took the time to reason through. How many times have you written a quicksort or a JSON parser in a new language? How many times do you think all the programmers in the world have, combined? Never again…
- Readability: Because ADHOC is “Action-Oriented”, reading a program is like reading a natural language. At the highest levels, everything is verbs, and with the right imports from the database, you should never have to deal with the nitty-gritty details!
- Documentability: Every ADHOC action prompts for a comment, so it can build documentation as you go!
- Error-check…ability: Another advantage of the “Action-Oriented” model is that it naturally encourages “Ask The Duck” programming. ADHOC also includes a syntax checker in its front-end and a variety of optimizers and error-checkers in its back-end. It can’t catch every error, but it sure tries!
Where Can I See It In Action?
I encourage you to try the ADHOC demo. The demo has a built-in tutorial mode (still under development) that should get you going quickly. If you want a look under the hood, the back end code is available here, and the front end code is here.
News About ADHOC
pieman72 pushed to adhoc_front (Oct 15th, 2015):
Fixing mobile touch expand node issue.
The following is a transcript of a paper I wrote in late 2014 for Professor Aho’s “Advanced Topics in Programming Languages and Compilers” seminar at Columbia University. A PDF version of the paper is available here. [Read More]
It’s been a little while since I’ve written about ADHOC, and a slew of cool new features are in place now. In addition to a number of important bug fixes. [Read More]
ADHOC uses 8 datatypes to classify values. The types are:
- Boolean – a simple true/false value.
- Integer – a numerical value without a decimal. Depending on the target language, may have an upper and lower bound.
- Float – a numerical value with a decimal. Depending on the target language, may have an upper and lower bound, and a degree of precision. [Read More]
An ADHOC project consists of a tree of nodes, each of which represents a logical concept in programming. There are 6 main types of nodes in ADHOC:
- Action Nodes represent actions in the AOP model. They are generally composed of children that represent simpler actions. Actions belong to packages, and the root node for any project is always an action definition for the highest-level function of the project (e.g. “Run Web Server”). Once an action is defined, it can be used in other parts of the project. Some important system actions are already defined, and can be called from any project. Action definitions appear as green rectangles and action calls appear as blue rectangles.
- Group Nodes are a way of establishing relationships between other particular other nodes. The “serial group” indicates that any actions within it always be performed in sequence, while otherwise, sibling actions can may be performed concurrently at the discretion of the code generation process. Serial groups appear as dashed gray rectangles around their children. [Read More]