Give meaning and explanation with the fewest number of characters in a form that is most accepted by your team or community at large.

learn more… | top users | synonyms

-1
votes
2answers
74 views

Is there an abbreviation for “serialization”? [on hold]

Is there a shorter word for "serialization," suitable for naming a namespace? Looking for something more concise than my.namespace.serialization. For example, "codec" is a great shortening of ...
-3
votes
0answers
22 views

Optimal number of syllables in a mobile app name? [on hold]

What is the optimal number of syllables in a mobile app name? According to Google it is 2 syllables (i.e. Twitter, FaceBook, Google).
-2
votes
1answer
26 views

What is a good name for a database table or OOP class used to store multimedia? [closed]

I want to store images and video, and I obviously don't want to use the name "Image" as the database table, since that would be inaccurate. I've used "Media" in the past, but I don't like the idea of ...
3
votes
1answer
61 views

Namespace by topic or by purpose? [closed]

The project I'm working on has quite a few classes. These classes can be grouped in two different ways. I'm trying to decide which grouping is best as for namespacing. Currently I a set of user facing ...
-2
votes
2answers
71 views

Name for methods changing a object vs. creating a new one [closed]

I encountered a naming problem while writing a vector class. Basically I have two different versions of each method, one which returns a new object and one that changes the object, the method is ...
0
votes
2answers
65 views

What's a good way to name dictionaries? [closed]

If I have an array of events [Event] and a dictionary of events [Int:Event]. What is a good way to name the two? let events = [Event]() let eventsDictionary = [Int:Event]() The above isn't feeling ...
-7
votes
3answers
157 views

Why different languages have different syntax? [duplicate]

Different programming language always/most of the time use different syntax. For example take PHP, Java and Python. In Php & Java semicolons are compulsory at the end of the line, yet Python ...
0
votes
0answers
45 views

Naming a class: Shadowing or Mirroring or something else?

The following class basically seeks to maintain a copy of the contents of a JMS Topic. The method onMessage() is called whenever a Messages arrived on a JMS Topic. public class TopicListener { ...
1
vote
2answers
97 views

Naming convention for getting the primitive backing a type?

I have a class that is backed by a double value, and I am wondering about accessor method names that preserve abstraction. Based on my experience in Java, there seems to be at least two precedents: ...
1
vote
2answers
63 views

Use of “this” in Golang

On the closest thing Golang has to a style guide found here, under Receiver Names this is written: The name of a method's receiver should be a reflection of its identity; often a one or two letter ...
-1
votes
1answer
66 views

How to name methods where one takes a single object as input and one takes multiple? [closed]

I have two methods in my class: public String widgetToHtml(Widget widget){...} and public String widgetsToHtml(List <Widget> widgets){ for(Widget widget : widgets){ ...
0
votes
1answer
30 views

Name pattern for quickly find descendents with SQL (PATH column with [TopId]…[DirectAncestorId].[OwnId]) NO nested sets

I read a long time ago about a pattern/technique for easily querying for all "descendants" of a record (no need to use CONNECT TO, which is not standard and not available with JPA). I remembered the ...
15
votes
4answers
473 views

Semantically more appropriate package name than `util` for the following things?

As a strawman consider the package java.util it is a dumping ground for various classes that in most cases do not share anything in common other than the person that put them there was lazy or ...
3
votes
4answers
1k views

What do you call an iterator that returns the current, previous and next siblings of each node of a list? [closed]

What do you call an iterator that given a list [a, b, c], returns an object of the form { prev, curr, next } for each iteration? e.g, (? === undefined) { prev: ?, curr: a, next: b } { prev: a, curr: ...
1
vote
1answer
96 views

Client/Server naming convention [closed]

I have a class that is a implements an API of a server component but get its input from another server, making it effectively both server and client. Assuming that the server interface is called ...
15
votes
7answers
1k views

What's the idea behind naming classes with “Info” suffix, for example: “SomeClass” and “SomeClassInfo”?

I'm working in a project which deals with physical devices, and I've been confused as how to properly name some classes in this project. Considering the actual devices (sensors and receivers) are one ...
1
vote
4answers
203 views

Is there a name for refactoring technique that turns hardcoded values into configurable parameters?

What is that technique called when you take values in the code that are hardcoded and make them variable, possibly constructing elaborate OO constructs to make that variable properly configurable? ...
1
vote
2answers
111 views

Should method names getX and setX only be used for fields and have no other effects? [duplicate]

Should I avoid using getX() and setX() as names for methods that aren't "traditional" getters or setters? (Let's define traditional as it only gets/sets the field and has no other effects.) I guess ...
1
vote
1answer
78 views

How to name complex DAL/repository methods? [closed]

I'm beginning working with repository pattern. When it comes to simple queries I don't have problems with names. GetById GetByDay UpdateById If a method retrieves data filtered by two values also ...
2
votes
1answer
93 views

Ambiguity of seemingly clear method names in APIs

(The question is language-agnostic, but to illustrate the point, I wrote the examples in C#.) Say I'm trying to model the behavior of "components" that communicate via "ports". I might model this ...
3
votes
2answers
93 views

How to deal with libraries that use different naming conventions?

I'm working on a personal project that uses a few different libraries, such as GLFW, glm and Bullet. How are different naming conventions usually dealt with in this context? Working with C++ I always ...
0
votes
1answer
69 views

Vector API, naming for element-wise multiply [closed]

I'm helping develop a 3D Vector class, which has common operations such as: v = v1.cross(v2) v = v1 * v2 - infix multiply for dot product. v = v1 + v2 - infix addition. v = v1.slerp(v2) - spherical ...
3
votes
0answers
69 views

Is there an industry standard term for a build which uses the production API, but is specifically for internal testing? [closed]

I'm working on clearing up our build processes of a PhoneGap app we're developing for iOS and Android, and I want to develop a concise naming scheme for our different build types. Here's what I'm ...
2
votes
2answers
138 views

Immutable vs Read-only vs Unmodifiable naming difference

So, I've looked at some similar questions asked here in regards to how these three should be used in naming. Usually, the answer is something along the lines of "it's conventional" and "just be ...
1
vote
2answers
83 views

How to organize code which converts from one type to another

If I have a DateRange class, and I want to translate a DateRange into SQL (e.g. some_col >= '2015-3-5' AND some_col <= '2015-3-5'), where should I put the method that does the translating? ...
0
votes
2answers
132 views

What naming convention should you use for data objects solely meant for parameters

This is my pseudocode for DAL: CusOrderDTO GetCustomerOrder(DateTime OrderDate, string customerCode) CusOrderDTO orderSet = new CusOrderDTO() * query data from database, populate CusOrderDTO ...
1
vote
1answer
113 views

How to name a function that makes sure an element exists and returns it?

function getOrInsertEmptyElemById(id){ var elem = $(id) || document.body.insert('<div id="'+id+'"></div>'); return elem; } I find myself using functions like the above quite ...
0
votes
0answers
20 views

two types of backend user and admin panels

Backend consists of two parts: implementing website logic (user-facing-backend) implementing admin panel (administration-backend) Is there a name for these parts? I want to create a tickt asking to ...
2
votes
1answer
111 views

How to deal with server-side and client-side naming conventions that clash? [closed]

I have a project that uses the underscore naming convention for the MySQL database and PHP scripts but uses camelCase for the javascript application (a common scenario I'm sure). However, once JSON ...
0
votes
5answers
203 views

Is it bad form to use the same variable name in different scopes?

Say you have some basic code where similar operations will take place in nearby lexical scopes. Take for example some simple pseudo code: variable = "foo" # Do something with variable if (True) { ...
2
votes
3answers
158 views

8085 assembly question. Why flag stacks named d0-d7?

I'm trying to make my C programming exciting by learning assembly programming. I've encountered an image of flag registers in 8085 assembly programming. In that image blocks are named from ...
2
votes
2answers
175 views

Should naming conventions be consistent or not across multiple programming languages in one project? [duplicate]

I saw this question on SO: here; the question is kind of old and not many viewed, so I want to ask it again. I currently work on a project using C++, C# and Actionscript-3, the conventions of C++ and ...
0
votes
1answer
55 views

Naming Active-Low Outputs [closed]

I'm writing some software for an embedded system. I am trying to think of clear names for my single pin output functions. Normally, when I'm working with active-high outputs (ON = 1, OFF = 0), I am ...
4
votes
1answer
88 views

Should enumerated types by pluralized? [closed]

I'm trying to decide how to name my enums. First I tried plural: private enum Positions { LEFT, RIGHT, UP, DOWN } private Positions pos; // ... public void setPosition(Positions newPosition) { pos = ...
3
votes
2answers
86 views

How to use scala case classes when delegation is needed

Let's assume in our application we want to model cars. We also want to model a car repository where we store some registered cars. How should that be modeled in scala? Here comes my approach: First, ...
1
vote
0answers
41 views

Naming Question: How to call a class that uses many Adapters ?

I have an application with many Value Objects. In many cases I want a convert from an Entity to a Value Object. Usually I have an Adapter for each scenario for example LanguageEntity to Locale and ...
3
votes
3answers
318 views

Object creation: when should I expose a factory vs wrapping class?

I am having some problems trying to figure out when to use a factory or to wrapper class. This question is slightly geared towards C# I guess, so I'm not sure if this is the correct place to ask. Say ...
0
votes
1answer
122 views

Term to describe pre-canned objects for use in testing

I have forgotten the term for a class that provides pre-canned objects for use as test data. e.g. If I'm testing a payment module and I need credit card objects of different types, I might have a ...
0
votes
1answer
86 views

How to design method that returns a compact representation of sourcecode

Let's say we have a class that stores some textlike content like sourcecode as a string. We want the class to be able to not only show the sourcecode itself but also a more compact representation. My ...
0
votes
1answer
155 views

What do you call classes that do arbitrary work in your project? [closed]

I work on a lot of projects with different teams. Every project has its own conventions, including what to call arbitrary classes that don't lend themselves to obvious names. As a counter-example, ...
0
votes
1answer
81 views

Does a create() method exist as part of a pattern? [closed]

Is there something special(i.e. a design pattern being related) to a method named create()? Background The case is, I often make some instances of objects (of the same class/prototype). These ...
1
vote
0answers
65 views

type name for state machine state (as opposed to other state variables)

I need to create a typedef for a state machine state, e.g. enum ToasterStateMachineState { TSM_READY, TSM_TOASTING, TSM_DONE }; But ToasterStateMachineState seems verbose and redundant; is ...
0
votes
1answer
107 views

Inverse property naming (ORM scenario) [closed]

I have a class that represents a process. In this process there are inputs boxes and output boxes. public class Process { public long ProcessId { get; set; } public virtual List<Box> ...
2
votes
4answers
204 views

Is naming a class based on its implementation acceptable?

Is naming a class according to its implementation an acceptable practice? e.g. SortedSet if the class is maintains a sorted list of unique items or TreeSet if it using a binary search tree structure ...
14
votes
10answers
2k views

Why do we use non-descriptive internal codenames? [closed]

I think using codenames are quite widespread. Our company is using them too. But my main concern is these names are usually not documented anywhere. And the meaning is spread by the word of mouth. ...
1
vote
1answer
213 views

Human names in programming examples [duplicate]

In small programming examples, it is established that one will probably use foo, bar, and/or baz as variable/function names. Are there accepted human names one can use? For example, if a program is ...
1
vote
3answers
141 views

negative boolean expressions and eager boolean OR

I come across these kinds of expressions and I have hard time reading it. How do you read it properly to see if it is the right logic when debugging. if (!(userLoggedIn || isAdmin)) { ...
-1
votes
2answers
89 views

Should I put the name of the method I'm testing in the Unit Test method's name/assert message?

Given that a method's name might change in time, is it a good idea to specify the name of the method whose return value I am asserting as a part of the Unit Test method's name? What about the message ...
3
votes
2answers
4k views

Naming conventions DAL, BAL, and UI Layer [closed]

I am developing a typical Web Application with the following layers UI Layer (MVC) Business Logic Layer (BAL) Data Access Layer (DAL) Each layer has its own DTO object including the BAL and DAL. ...
1
vote
1answer
112 views

What are classes that produce a result, but are necessarily classes because of the complexity of the task?

What generic name is given to classes that encapsulate a collection of esoteric functions which together perform some larger cohesive but entirely self-contained task useful to the wider application, ...