|
I'm working on a large project where, even with 10s of 1000s of automated tests and 100% code coverage, we're getting a ridiculous number of errors. About 95% of errors we get are NullReferenceExceptions.
Is there any way to enforce null-checking at compile...
Started by Juliet on
, 13 posts
by 13 people.
Answer Snippets (Read the full thread at stackoverflow):
Public void MyMethod(!string occurrences for external callers to pass null values and then enforce null checks on public facing InternalClass { public void DoSomething....
To enforce compile time null reference checks by using an ! modifier.
|
|
Hi all,
I'm using Exchange 2007 and we've never assigned mailbox storage limits, many users will have old mail that can now be removed. How can I assign a storage policy and have it enforce it?
Thanks Steve
Started by Steven on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at serverfault):
enforce mailbox quotas at two levels in Exchange 2007:
Database Level You can set the mailbox quotas","Wed.2:00-Wed.3:00"
Replacing the values in <> with your values
Mailbox Level You can enforce.
|
|
Is there a way to enforce constraint checking in MSSQL only when inserting new rows? I.e. allow the constraints to be violated when removing/updating rows?
Update: I mean FK constraint.
Started by Brian R. Bondy on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
However, I'd quibble.
To be "enforce the insert requirements in your data access layer".
|
Ask your Facebook Friends
|
Would really like to be able to decorate my class with an attribute of some sort that would enforce the use of a using statement so that the class will always be safely disposed and avoid memory leaks. Anyone know of such a technique?
Started by Bigtoe on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
See the Wikipedia for a quick overview.
You could use FxCop to enforce this rule.
|
|
What gcc options shall I use to enforce ANSI C (C99) warnings/errors? gcc (GCC) 3.4.2 (mingw-special)
I'm using: gcc -pedantic -ansi -std=c99 is this correct?
Started by AlfaTeK on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
The -ansi flag is synonymous with the....
Also, -Wall might also be of interest, but only -pedantic should do what you want .
ANSI C isn't the same as C99 (yet).
In C++ mode, it is equivalent to -std=c++98.
Ansi In C mode, this is equivalent to -std=c89.
|
|
My app needs to run on 10.4 or later. If I launch it on 10.3 it just fails to launch or crashes.
How do you tactfully enforce minimum system requirements? Can you customize the message it shows?
Started by zekel on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
I have not used either of these techniques/advice, just passing along the information... .
For more, see Apple's documentation.
Add a key to your applications Info.plist, specifying LSMinimumSystemVersion as 10.4.X for whatever X you need as a minor version .
|
|
I have a table in MySQL that has 3 fields and I want to enforce uniqueness among two of the fields. Here is the table DDL:
CREATE TABLE `CLIENT_NAMES` ( `ID` int(11) NOT NULL auto_increment, `CLIENT_NAME` varchar(500) NOT NULL, `OWNER_ID` int(11) NOT ...
Started by Mike Farmer on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
It's much more efficient....
For the UTF8 charset, MySQL character string.
Here.
Get MySQL to enforce uniqueness on that hash instead.
UNIQUE?
MySQL cannot enforce uniqueness on keys that are longer(CLIENT_NAME).
Have you looked at CONSTRAINT ...
|
|
I'm trying to implement a tree like structure using a Materialized Path model described here: http://www.dbazine.com/oracle/or-articles/tropashko4 .
Is it possible to enforce referential integrity on the [path] field? I don't see how SQL could do it, ...
Started by hyperslug on
, 3 posts
by 3 people.
Answer Snippets (Read the full thread at stackoverflow):
You can easily enforce.
Yes, you have to enforce data integrity yourself in the DAL when you use either Materialized Path is then the id of the direct children with the last character removed .
|
|
I was wondering what mechanism have people used to enforce and track peer reviews for committing to SVN.
For each commit I want to be able to track if people have had a peer review (I am not sure whether enforcing a rule where they can't commit is a good...
Started by Dean on
, 5 posts
by 5 people.
Answer Snippets (Read the full thread at stackoverflow):
However before the changes are merged....
Then the rule that no code may be committed without a peer review needs .
If you use greenhopper for planning development tasks too, you can enforce that all to enforce this if you need to.
In the commit.
|
|
I have a device (digital indicator) that I am communicating with using the SerialPort class. The device documentation states that I need to have a 250 millisecond delay between writes. Is there a way to enforce this without putting extra delay into the...
Started by Max Schmeling on
, 4 posts
by 4 people.
Answer Snippets (Read the full thread at stackoverflow):
If you need precise timings, you'd better use spin waits... .
Suspending the thread should work for you:
System.Threading.Thread.Sleep(250);
However, this can be a little inaccurate since you can't guarantee the next time your thread is going to be scheduled .
|