FAQ Database Discussion Community


What is the correct graphical representation of an empty UML class?

uml,class-diagram,representation
Most UML tools represent an empty UML class with empty fields for both, attributes and operations. But looking at the UML Infrastructure and Superstructure, there are a lot of empty classes shown as one single rectangle including the name of the class. But I cannot find a clear statement which...

Create full Representation of JSON

json,representation
I am trying to create a full JSON representation of Scan: Scan Id: 3 article: 3 user: 1 created_at: 2015-05-04 is_purchased: true Article id: 3 title: Lelles bread brand: Bear quantity: 5.243 entity: oz created_at: 2014-04-21 User id: 1 firstName: Frans lastName: Anderson userName: FRAN mail: [email protected] Is this JSON...

String representation of a class in Python 3

python,class,python-3.x,class-variables,representation
I'd like my classes to have a string representation which is based on a class variable (which may be different in derived classes). This answer suggests that metaclasses might be the way to go: class MC(type): def __repr__(self): return 'Wahaha!' class C(): __metaclass__ = MC print(C) But this doesn't work...

Gaps between successive floating point numbers

numbers,computer-science,representation
(all numbers discussed are in decimal) lets say we have a floating point data type that is like : m * 10 ^ e where m is the mantissa . and max mantissa size is 1 ( 0 <= m <= 9); e is the exponent and its size is...

Handling missing values in a database schema?

database-design,modeling,missing-data,representation
Suppose I have the following table schema MONTH VARCHAR(10) HASRAIN BOOLEAN YEAR INTEGER Now suppose for a particular year, I have values for 11 months, but no value for the the left over month (let's call it September). Is it more correct to: Put a record in with a zero...

DDD: naming convention for Representation Layer and Domain Layer classes

java,rest,domain-driven-design,representation
I apologize in advance because this question is almost a bit silly. Nonetheless, I can't come up with a good solution myself, so I thought it still worthwhile to ask. What does one do when the Representation object and the Domain object should have the same name? The DDD Sample...

Number of numbers between 2 and 3 in IEEE-754

numbers,ieee-754,representation
i am learning IEEE-754 representation of numbers. I know how to convert from binary to IEEE and on vice versa. Now i am trying to figure out how to find out how many numbers in single precision are for instance between 2 and 3. So, the sign will be the...