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
vote
1answer
278 views

Name for a tree where nodes hold a reference to their parent as well as their children

I am creating a tree where some nodes have a reference to their parent as well as their children. It feels like a tree version of a doubly linked list. Is there a name for this?
39
votes
7answers
3k views

How to name a variable when the word is both a noun and a verb

I have run into a corner-case problem with the general guidance of: nouns for variables verbs for functions Specifically, I have a case where the word is ambiguous - it can be either a verb or a ...
1
vote
2answers
103 views

Name for intentionally assertless unit test [closed]

I have a tool that is going to be run as part of commit stage on Continuous Integration server to check whether all unit tests run do have an assert. Its main purpose is to eliminate silly mistakes ...
7
votes
5answers
249 views

Word for the superset of files and folders

I'm trying to come up with a name for a class that can represent both files and folders. Anyone know a word for this?
3
votes
1answer
152 views

Advices on structure and names for namespaces and classes [closed]

I'm resistant to calling the "main" class the same as the namespace, but I sometimes find myself needing it. Considering I'm using the Vendor.Namespace.[Subnamespace].Class formula, imagine this ...
13
votes
8answers
790 views

How and why to decide between naming methods with “get” and “find” prefixes

I always have trouble figuring out if I should name a certain method starting with getSomething versus findSomething. The problem resides in creating helpers for poorly designed APIs. This usually ...
3
votes
1answer
111 views

Representing domain objects

This is related to my recent question regarding naming awkward domain objects. A number of answers indicated I was using the wrong representation for the domain objects. To summarize, I chose to use ...
11
votes
6answers
457 views

Guidance in naming awkward domain-specific objects?

I'm modeling a chemical system, and I'm having problems with naming my elements / items within an enum. I'm not sure if I should use: the atomic formula the chemical name an abbreviated chemical ...
5
votes
3answers
604 views

Why the name 'continue' [closed]

The 'continue' keyword in Java (and probably in many other programming languages) is used to skip further execution of the current iteration. Why was the name 'continue' chosen? Why not something ...
4
votes
1answer
304 views

Java-style package naming and second-level country domains

I own a .co.uk domain, and I whenever I've dealt with Java-style package naming, I've gone with uk.co.domainname. Once I encountered package that did the following: co.uk.domainname. Is one of these ...
1
vote
1answer
140 views

Am I missing a pattern?

I have a class that is a singleton and off of the singleton are properties that hold the instances of all the performance counters in my application. public interface IPerformanceCounters { ...
1
vote
6answers
681 views

“Mac” vs “OS X” vs “Mac OS X” [closed]

I am writing server software that gives administrators options that apply only to Mac OS X clients. When naming those options, I need to decide how I am going to refer to such clients. I can see three ...
3
votes
1answer
344 views

Distinguishing between UI command & domain commands

I am building a WPF client application using the MVVM pattern that provides an interface on top of an existing set of business logic residing in a library which is shared with other applications. The ...
6
votes
3answers
2k views

What should I use for a package name if I don't have a domain? [duplicate]

Possible Duplicate: What is the point of Java’s package naming convention? What package name to choose for a small, open-source Java project? I write Java (and derivative languages with ...
4
votes
2answers
2k views

Naming convention: field starting with “m” or “s”

I saw lot of code (for example some Android source code) where fields name start with a "m" while static fields start with "s" Example (taken from Android View class source): private ...
-1
votes
4answers
135 views

Identifier for the “completed” stage of a process: 0, 99, something else?

Say, that you are handling a multi-step process (like a complex registration form, with a number of steps the user has go through in order). You need to be able to save the current state of the ...
2
votes
4answers
253 views

Function names - “standardized” prefixes

Imagine you have such routines /*just do X. Fail if any precondition is not met*/ doX() /*take care of preconditions and then do X*/ takeCareOfPreconditionsCheckIfNeededAtAllAndThenDoX() A little ...
99
votes
16answers
20k views

Is there an excuse for short variable names?

This has become a large frustration with the codebase I'm currently working in; many of our variable names are short and undescriptive. I'm the only developer left on the project, and there isn't ...
5
votes
3answers
210 views

How to name an subclass that add a minor, detailed thing?

What is the most concise (yet descriptive) way of naming a subclass that only add a specific minor thing to the parent? I encountered this case a lot in WPF, where sometime I have to add a small ...
2
votes
1answer
378 views

What is meaning of the term “Sans” in a class name?

I was reading code of a java project where I found a class name like "UserSansXml". This class is dealing with user objects. I wanted to know the meaning of "sans".
5
votes
3answers
623 views

Inspection, code review - is it really testing?

ISTQB, Wikipedia or other sources classify verification acitivities (reviews etc.) as a static testing, yet other do not. If we can say that peer reviews and inspections are actually a kind of a ...
4
votes
2answers
765 views

Naming methods that do the same thing but return different types

Let's assume that I'm extending a graphical file chooser class (JFileChooser). This class has methods which display the file chooser dialog and return a status signature in the form of an int: ...
2
votes
2answers
293 views

What do you call a queue when the word queue is reserved?

I'm working on a rails app, and in rails queue is a reserved word. I need to make a Queue model for my app, and I'm stuck because I don't know what else to call it. Has anyone else run into this ...
3
votes
2answers
574 views

What package name to choose for a small, open-source Java project?

I'd like to publish a small open-source library in Java. I wonder what package name should I choose? I'm not a company and I don't have a domain that I could use as the basis for naming the package ...
3
votes
7answers
316 views

Vocabulary: Should I call this apply or map?

So, I'm tasked with organizing the code and building a library with all the common code among our products. One thing that seems to happen all the time and I wanted to abstract is posted below in ...
2
votes
1answer
416 views

What should be done with class names that conflict (common) framework names

What should be done exactly when the most obvious class name for a component is taken by a framework? In my case, I need to make a class that describes an HTTP request. Of course, the most common name ...
5
votes
3answers
708 views

Naming Convention for Dedicated Thread Locking objects

A relatively minor question, but I haven't been able to find official documentation or even blog opinion/discussions on it. Simply put: when I have a private object whose sole purpose is to serve for ...
3
votes
4answers
348 views

Is it bad practice to use the same name for arguments and members?

Sometimes I write constructor code like class X { public: X( const int numberOfThingsToDo ) : numberOfThingsToDo( numberOfThingsToDo ) { } private: int numberOfThingsToDo; }; or in C# ...
1
vote
1answer
123 views

External file (images, sounds) naming convention at Xcode

What is better naming conventions at Xcode regardng External File (images, sounds) etc? Is there any guideline from vendor Apple? As we store our projects at SVN, is there any complicity from Hosted ...
3
votes
1answer
107 views

Naming a class that processes orders

I'm in the midst of refactoring a project. I've recently read Clean Code, and want to heed some of the advice within, with particular interest in Single Responsibility Principle (SRP). Currently, ...
2
votes
2answers
127 views

Naming variables with fixed point units

What should I name a variable that has units with a fixed point? int herpLimitLo_psig2 = 6000; // 60.00 psig int derpLimitLoPsigwithtwodigits; int herpLimitHiPsigfixedtwo; int ...
9
votes
4answers
428 views

How to avoid general names for abstract classes?

In general it's good to avoid words like "handle" or "process" as part of routine names and class names, unless you are dealing with (e.g.) file handles or (e.g.) unix processes. However abstract ...
2
votes
2answers
274 views

Case Class naming convention

In my recent adventures in Scala, I've found case classes to be a really nice alternative to enums when I need to include a bit of logic or several values with them. I often find myself writing ...
36
votes
11answers
3k views

Why are cryptic short identifiers still so common in low-level programming?

There used to be very good reasons for keeping instruction / register names short. Those reasons no longer apply, but short cryptic names are still very common in low-level programming. Why is this? ...
3
votes
5answers
496 views

How do you name your personal libraries?

I'm pretty bad with naming things. The only name I can every generically come up with is 'helper'. Say, if I have a header file that contains helping functions for manipulating paths, I tend to put ...
4
votes
3answers
307 views

Naming a “do X if needed” method

What is a good way to name a method that checks if X needs to be done, and does X it if necessary? For example, how to name a method that updates a user list if new users have logged in? ...
26
votes
6answers
955 views

In what language should I name my business classes?

I'm requesting best practice with this question. This is only an issue if the customer company is strictly national has a native language other than English, I think. If the customer has a lot of ...
17
votes
5answers
1k views

What are the benefits of prefixing function parameter names with p*?

I often see projects (in Java projects and teams using Eclipse) that prefix function parameters with p. For example public void filter (Result pResult) ... I personally don't see any benefit in ...
0
votes
2answers
132 views

Name of a class that creates a bunch of classes for a process [closed]

We all know that the hardest parts of computer science deal with cache invalidation and naming things; my problem is the latter. I have a process that raises events when various things happen. Rather ...
6
votes
5answers
2k views

What do you call classes without methods?

What do you call classes without methods? For example, class A { public string something; public int a; } Above is a class without any methods. Does this type of class have a special name?
4
votes
6answers
350 views

Order of subject and modifiers in variable names

I'm looking for experiences regarding the ordering of the subject and modifiers in variable names. A simple object Shape would have just a subject for the variable name, such as Area. A slightly ...
14
votes
1answer
1k views

Why does the C library use macros and functions with same name?

I am reading 'The Standard C Library' by PJ Plauger which is really interesting. The book explains not only how to USE the library but also how it is implemented. I have finished reading the ctype.h ...
0
votes
1answer
238 views

Coincidence or rule?

I was reading about Assemblies (modules, which Microsoft CLR works with). The Assembly contains so called Manifest, which by definition describes a set of files in the Assembly. I know that Android ...
8
votes
1answer
296 views

Why does XMLHttpRequest not seem to follow a naming convention?

I've been working with the XMLHttpRequest object in JavaScript recently, and I couldn't help but notice that the casing of this name makes no sense. Why is 'XML' all in caps while 'Http' is not? ...
1
vote
2answers
535 views

Nice iterator naming [closed]

How do you name your iterators when you return a begin and an end iterator from a class? Without it sounding clunky, that is. Example: typedef std::vector<Idea> Ideas_Type; ...
2
votes
3answers
320 views

What's a better name for this many-to-many table?

Part of one of my applications has contracts and contract_types tables, wherein a type may have many contracts but a contract may only be of one type. Now a new wrinkle has been introduced: a contract ...
2
votes
1answer
79 views

Variable names for Contact Information bits [closed]

I am in the middle of refactoring code and would like to get some ideas on variable naming so that my new names clearly represent the data they hold. I have a class called ContactMethod which makes ...
2
votes
1answer
94 views

Naming library which generates a JSON-req to a REST-API?

How would you call a library which generates a JSON-req to a REST-API so that you just work on object-level for creating a request? Many company wants to define it as an SDK, but is it a suitable ...
2
votes
6answers
381 views

How to define a natural id in database?

There are a lot of manuals. I am trying to create an database to hold information of these documents. But, there is a small problem. How can I give meaningful id to the manuals? Are there any standard ...
1
vote
4answers
558 views

CamelCase issue (PList or Plist)

Ok, I understand what CamelCase is. This question is relating to how to CamelCase the shortened version of Property List (PList). I am asking this because I am working on a PList parser in C# and ...