Wiki source code of Glossary

Version 4.1 by chrisby on 2022/12/31 18:07

Show last authors
1 (% class="box infomessage" %)
2 (((
3 (% style="text-align: justify;" %)
4 The explanations given here do not claim to be complete. They merely serve as a brief description to give an idea of the respective term. For more detailed information, the Internet should be consulted.
5
6 (% style="text-align: justify;" %)
7 Note that some of these technical terms are fuzzy, overlap with other terms, or have different meanings depending on the context or the people using them. This Glossary is an attempt to structure these terms in a concise manner. Be open to variations as you talk and work with other developers.
8 )))
9
10
11 |**Term**|(% style="text-align:justify" %)**Explanation**
12 |Abstraction|(% style="text-align:justify" %)(((
13 1. The counterpart of "Concretion". It refers to interfaces and abstract classes that define behavior, namely function signatures, but do not contain information about internal operation.
14 1. A generic, high-level unit. For example, a class contains two functions that contain duplicate code, which should not happen according to the DRY principle. The duplication can be resolved by moving the duplicate code to a common function (the "Abstraction" of that code) and calling the function where the code was previously located. The duplicate code was "abstracted".
15 )))
16 |Assertion|(% style="text-align:justify" %)An assertion function is used in "Test Code". When an unexpected input values are provided, it causes the test containing it to fail. Example call: "assertEquals(expectedResult, actualResult)".
17 |Aware/Unaware|(% style="text-align:justify" %)The class A contains a source code reference of the class B and therefore is aware of the class B. If you were to read only the source code of class A, you would know that there must be a class B. If there was no such reference, class A would be unaware of class B.
18 |Best Practices|(% style="text-align:justify" %)Generally accepted guidelines aimed at increasing your programming productivity. If you take them seriously, you will save yourself a lot of pain.
19 |Concretion|(% style="text-align:justify" %)(((
20 It is the counterpart of "abstraction" and is sometimes called "implementation". It refers to classes that implement interfaces or inherit from abstract classes. It defines the internal workings of the functions it must provide by containing the "concrete" code.
21 )))
22 |[[Constructor Injection>>doc:Software Architecture.Dependency Injection.Types of Dependency Injection.WebHome]]|(% style="text-align:justify" %)Dependency Injection performed by passing a dependency to an instance via constructor argument.
23 |Component|(((
24 1. In Spring, it is a generic annotation for a bean that no other Spring Bean Annotation matches: "@Component".
25 1. In software architecture, it is a module that can be executed independently. It is often compiled and/or compressed into an executable such as a .jar or .exe file.
26 )))
27 |Data Structure|(% style="text-align:justify" %)A very simple type of class that contains only data and no logic. For example, a class that has only public fields but no methods. Another form is a class with private fields and simple corresponding getters and setters.
28 |Dependency|(% style="text-align:justify" %)In the context of classes, a dependency is a field that must be initialized with an instance of another class in order for an object of that class to function properly. Often, the initialization is realized via Dependency Injection.
29 |Dependency Cycle|(% style="text-align:justify" %)For example, an instance of one class requires an instance of another class to be constructed, and vice versa. So both classes need the other dependency to construct an instance. Therefore, it is impossible to construct either instance at all. Always make sure that the dependency graph looks like a directed acyclic graph.
30 |[[Dependency Injection>>doc:Software Engineering.Dependency Injection.WebHome]] (DI)|(% style="text-align:justify" %)An object is injected with the dependencies it needs instead of constructing them itself.
31 |Dirty|(((
32 (% style="text-align: justify;" %)
33 ~1. Messy, unreadable, or poorly designed code is referred to as "dirty code". Often associated with code written "quick-and-dirty" due to time pressure.
34
35 (% style="text-align: justify;" %)
36 2. The term comes from the phrase "getting one's hands dirty" and refers to coding work that is considered monotonous, detailed, low-level and undemanding, but necessary. The term is often used in the context of I/O operations. Creating a database transaction, for example, is always handled very similarly and is not considered a fun task for experienced programmers who have done it many times. High-level design is more exciting because it requires more creativity from the developer and is more intellectually stimulating.
37 )))
38 |Dynamic|(((
39 (% style="text-align: justify;" %)
40 Often refers to processes which appear at runtime when the code has already been executed and is "running". Examples:
41
42 * Dynamic dependencies are dependencies which can be replaced at runtime.
43 * Dynamically typed languages determine the type of an object at runtime.
44 )))
45 |Entity|(((
46 (% style="text-align: justify;" %)
47 ~1. In an object context, this means that two objects of the same type that contain exactly the same values in their fields can be considered equivalent, but are still two separately existing entities.
48
49 (% style="text-align: justify;" %)
50 2. In the context of software architecture, the term refers to classes that represent the model of the application and often represent things from the real world. For example, a banking application may have entity classes such as //Account//, //Order//, //Customer//, or //Employee//. They are often built like simple Data Structures, but may contain additional validation logic to impose logical constraints on their fields. For example, the integer field //customer.age// must always be between 0 and 150 because that is a logical constraint on people's ages, even though the integer data range is technically much larger.
51 )))
52 |[[Field Injection>>doc:Software Architecture.Dependency Injection.Types of Dependency Injection.WebHome]]|(% style="text-align:justify" %)Dependency Injection is performed by forcibly injecting a dependency into an instance through the use of reflections that break even the encapsulation measures. This type of Dependency Injection is to be avoided.
53 |[[Inversion of Control>>doc:Software Architecture.Dependency Injection.Dependency Injection Explained.WebHome]] (IoC)|(% style="text-align:justify" %)Transfers the responsibility of defining the logic and order of Dependency Injections from the developer to computer.
54 |JavaBean|(((
55 (% style="text-align: justify;" %)
56 A design convention for data structures. Usually it means a class which has:
57
58 * a public no-argument constructor
59 * only private fields
60 * only getters and setters for each field as methods
61
62 (% style="text-align: justify;" %)
63 Often, DTO's and entities follow this convention.
64 )))
65 |Logic|(% style="text-align:justify" %)Any code with non-trivial complexity can be referred to as "logic". In contrast, for example, getters and setters have trivial complexity.
66 |Magic|(% style="text-align:justify" %)"Code that handles complex tasks while hiding that complexity to present a simple interface."^^[[[sources]>>url:https://en.wikipedia.org/wiki/Magic_(programming)]]^^ For example, the introduction of the Spring IoC container is quite simple, but the logic and wiring that goes on in the background is complex.
67 |Pain|(% style="text-align:justify" %)Something causes pain when somebody spend unnecessary and great effort on a task that often could have been prevented by better code design.
68 |Production Code|(% style="text-align:justify" %)The counterpart of the Test Code. It contains all the code required to run the application.
69 |Runtime|(((
70 (% style="text-align: justify;" %)
71 The time period in which the code is executed. For example:
72
73 * An exception is thrown by the compiler that finds an invalid syntax in the source code. This is called a compile-time exception.
74 * Suppose that after a successful compilation, an executable file was created, started, and an exception was thrown shortly thereafter. Since this happened at runtime, it is a runtime exception.
75 )))
76 |Separation of Concerns|(% style="text-align:justify" %)A principle that says that programs should be modular, with each module taking care of a different aspect of the program.
77 |[[Setter Injection>>doc:Software Architecture.Dependency Injection.Types of Dependency Injection.WebHome]]|(% style="text-align:justify" %)Dependency Injection performed by passing a dependency to an instance via setter method argument.
78 |Spring Bean|(((
79 (% style="text-align: justify;" %)
80 A term used in Spring Framework for an object that is contained in the IoC container to be injected into other beans and/or to receive dependency injections. It is one of many components/beans that are wired together via IoC to form the application when it is started.
81
82 (% style="text-align: justify;" %)
83 Not to be confused with JavaBeans.
84 )))
85 |Static|(((
86 (% style="text-align: justify;" %)
87 Often refers to processes that depend non-running code. Examples:
88
89 * Static Code Analysis Tools can examine source code files for possible improvements.
90 * Statically typed languages determine the type of an object at compile time.
91 )))
92 |Test Code|(% style="text-align:justify" %)The counterpart of the Production Code. It is code that checks whether the production code works as expected. Test Code plays no role in the operation of an application.
93 |Test-Driven Development|(% style="text-align:justify" %)A workflow in which the developer implements code in small steps, incrementally and iteratively, defining tests at each iteration.
94 |Wiring|(% style="text-align:justify" %)The process of generating and injecting dependencies to set up an application performed by the IoC container.