unified_texts
stringlengths
32
30.1k
OpenStatus_id
int64
0
4
input_ids
list
token_type_ids
list
attention_mask
list
What, exactly, distinguishes between private and protected (in Flex)? === In Flex (and many other languages) a function/method of a class can be declared private or protected (or public). What's the difference? I have the impression it has something to do with the relationship to child classes and how things are inherited or can be called, but I'm not sure what, exactly.
0
[ 2, 98, 15, 1890, 15, 9705, 160, 128, 932, 17, 3803, 13, 5, 108, 14409, 6, 60, 800, 3726, 3726, 19, 14409, 13, 5, 290, 151, 89, 2556, 6, 21, 1990, 118, 5909, 1807, 43, 16, 21, 718, 92, 44, 2482, 932, 54, 3803, 13, 5, 248, 3...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Equivalent of Class Loaders in .NET === Does anyone know if it possible to define the equivalent of a "java custom class loader" in .NET? **To give a little background:** I am in the process of developing a new programing language that targets the CLR, called "Liberty". One of the features of the language is its ability to define "type constructors", which are methods that are executed by the compiler at compile time and generate types as output. They are sort of a generalization of generics (the language does have normal generics in it), and allow code like this to be written (in "Liberty" syntax): var t as touple<i as int, j as int, k as int>; t.i = 2; t.j = 4; t.k = 5; Where "touple" is defined like so: public type touple(params variables as VariableDeclaration[]) as TypeDeclaration { //... } In this particular example, the type constructor "touple" provides something similar to anonymous types in VB and C#. However, unlike anonymous types, "touples" have names and can be used inside public method signatures. This means that I need a way for the type that eventually ends up being emitted by the compiler to be shareable across multiple assemblies. For example, I want `touple<x as int>` defined in Assembly A to end up being the same type as `touple<x as int>` defined in Assembly B. The problem with this, of course, is that Assembly A and Assembly B are going to be compiled at different times, which means they would both end up emitting their own incompatible versions of the touple type. I looked into using some sort of "type erasure" to do this, so that I would have a shared library with a bunch of types like this (this is "Liberty" syntax): class touple<T> { public Field1 as T; } class touple<T, R> { public Field2 as T; public Field2 as R; } and then just redirect access from the i, j, and k touple fields to "Field1", "Field2", and "Field3". However that is not really a viable option. This would mean that at compile time `touple<x as int>` and `touple<y as int>` would end up being different types, while at runtime time they would be treated as different types. That would cause many problems for things like equality and type identity. That is too leaky of an abstraction for my tastes. Other possible options would be to use "state bag objects". However, using a state bag would defeat the whole purpose of having support for "type constructors" in the language. The idea there is to enable "custom language extensions" to generate new types at compile time that the compiler can do static type checking with. In Java, this could be done using custom class loaders. Basically the code that uses touple types could be emitted without actually defining the type on disk. A custom "class loader" could then be defined that would dynamically generate the touple type at runtime. That would allow static type checking inside the compiler, and would unify the touple types across compilation boundaries. Unfortunately, however, the CLR does not provide support for custom class loading. All loading in the CLR is done at the assembly level. It would be possible to define a seperate assembly for each "constructed type", but that would very quickly lead to performance problems (having many assemblies with only one type in them would use too many resources). **So, what I want to know is:** Is it possible to simulate something like Java Class Loaders in .NET, where I can emit a reference to a non-existing type in and then dynamically generate a reference to that type at runtime before the code the needs to use it runs? **NOTE:** *I actually already know the answer to the question, which I provide as an answer below. However, it took me about 3 days of research, and quite a bit of IL hacking in order to come up with a solution. I figured it would be a good idea to document it here in case anyone else ran into the same problem. *
0
[ 2, 4602, 16, 718, 6305, 445, 19, 13, 9, 2328, 800, 3726, 3726, 630, 1276, 143, 100, 32, 938, 20, 9267, 14, 4602, 16, 21, 13, 7, 1004, 1385, 5816, 718, 6305, 106, 7, 19, 13, 9, 2328, 60, 13, 1409, 262, 590, 21, 265, 2395, 45,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to Write a "Fake" ListBox === I use ListBox to show Images. However I found if the Listbox contain more than 1000 Image Items, It is really slow if I want to zoom the thumbnails. I asked the qestion in http://stackoverflow.com/questions/181845/in-a-wpf-listbox-with-more-than-1000-image-items-the-zoom-images-become-slow And tried lots of method, however I can't solve the problem by simply change the ListBox Property. Can I write a fake ListBox? It seems contain lots of images, but actually it just contain about 100 images as its items, it can support smooth scrolling and when the 100 images are out of current window, it can load another 100 images while users do not know it(without pause when change page). I have no idea how to write such a custom listbox, Anyone have a sample to do this trick? Thanks!
0
[ 2, 184, 20, 2757, 21, 13, 7, 1473, 1048, 7, 968, 5309, 800, 3726, 3726, 31, 275, 968, 5309, 20, 298, 3502, 9, 207, 31, 216, 100, 14, 968, 5309, 3717, 91, 119, 6150, 1961, 3755, 15, 32, 25, 510, 2276, 100, 31, 259, 20, 19469, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Initializing private static members === This feels like a dumb question, but what is the best way to initialize a private, static data member in C++? I tried this but it gives me weird linker errors: class foo { private: static int i; }; int foo::i = 0; I'm guessing this is because I can't initialize a private member from outside the class. So what's the best way to do this?
0
[ 2, 2104, 3335, 932, 12038, 443, 800, 3726, 3726, 48, 5121, 101, 21, 9317, 1301, 15, 47, 98, 25, 14, 246, 161, 20, 2104, 2952, 21, 932, 15, 12038, 1054, 322, 19, 272, 20512, 60, 31, 794, 48, 47, 32, 2352, 55, 5455, 3508, 106, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
New project, I am having troubles picking a language to use. === I am starting my first independent for profit venture. I am having a hard time deciding what language to use. I want to write my app in Perl, but I don't think it will be simple enough to compile. If I don't write it in Perl I will write it in C++. The application will have many features, including [wxwidgets][1] interface, Deal with SDL, timers, some threading, and audio processing. The program itself will be somewhat complex, but not terribly large. So my question's are: 1. Can PAR, Perl2exe, or equivalent compile more than a basic test cases? 2. Speed, and compilation aside why should I use C++ over Perl? [1]: http://www.wxwidgets.org/
0
[ 2, 78, 669, 15, 31, 589, 452, 16615, 7833, 21, 816, 20, 275, 9, 800, 3726, 3726, 31, 589, 1422, 51, 64, 1124, 26, 8583, 5998, 9, 31, 589, 452, 21, 552, 85, 11211, 98, 816, 20, 275, 9, 31, 259, 20, 2757, 51, 4865, 19, 416, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
MySQL 5 (32bits) on Windows 2008 server === As above, anyone tried that before on Windows 2008 server? If yes, how is everything go? Stable enough for production use?
0
[ 2, 51, 18, 22402, 331, 13, 5, 3125, 3326, 18, 6, 27, 1936, 570, 8128, 800, 3726, 3726, 28, 784, 15, 1276, 794, 30, 115, 27, 1936, 570, 8128, 60, 100, 1643, 15, 184, 25, 796, 162, 60, 4521, 511, 26, 637, 275, 60, 3, 0, 0, 0...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
QT: difference between moc output in debug and release? === Using the QT Visual studio integration, adding a new QT class adds two separate moc.exe generated files - one for debug and one for release (and one for any other configuration currently existing). Yet the two eventual generated files seem to be identical. On the other hand when adding a UI class, the uic.exe generated files don't have this separation and are the same file for all configurations. Does anybody have an idea why there's a need for a separate moc file for every configuration? When is there a difference between the two?
0
[ 2, 2593, 38, 45, 2841, 128, 22647, 5196, 19, 121, 16254, 17, 830, 60, 800, 3726, 3726, 568, 14, 2593, 38, 3458, 1120, 8078, 15, 4721, 21, 78, 2593, 38, 718, 10621, 81, 1725, 22647, 9, 1706, 62, 6756, 6488, 13, 8, 53, 26, 121, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I analyze a .hprof file? === I have a production server running with the following flag: -**XX:+HeapDumpOnOutOfMemoryError** Last night it generated a java-38942.hprof file when our server encountered a heap error. It turns out that the developers of the system knew of the flag but no way to get any useful information from it. Any ideas?
0
[ 2, 184, 107, 31, 16051, 21, 13, 9, 252, 2740, 410, 3893, 60, 800, 3726, 3726, 31, 57, 21, 637, 8128, 946, 29, 14, 249, 3157, 45, 13, 8, 1409, 8962, 45, 2430, 438, 2552, 12617, 8782, 1320, 1041, 790, 5171, 93, 29992, 1409, 236, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Deleting Visual Studio binary output folders automatically? === I just got through manually removing the `bin\` and `obj\` folders from around 30 VS projects getting them ready for an initial SVN commit. Yeah, I know, I should have done it alot sooner, but these are personal project on my home PC, and I only installed a SVN server locally today. Anyway, it occurs to me that there must be some easier way to clean out these folders, an option in Visual Studio, or an external tool, something... Does anyone have any suggestions, since I still have a few solutions left to do?
0
[ 2, 121, 1336, 68, 3458, 1120, 14171, 5196, 19294, 18, 7499, 60, 800, 3726, 3726, 31, 114, 330, 120, 23671, 9096, 14, 13, 1, 4772, 1, 17, 13, 1, 111, 11741, 1, 19294, 18, 37, 140, 712, 4611, 2314, 1017, 105, 1451, 26, 40, 2104, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Localization / internationalization tool === I'm looking to add localization to a web site (asp.net /c# if that makes a difference) with a minimum of effort. I've looked at tools like [wiztom][1] [multilizer][2] and but I am curious as to others experience with them. Have you used tools like these successfully and if so, what would you do differently? Thanks! K [1]: http://www.wizart.com/en/index.shtml [2]: http://www.multilizer.com/
0
[ 2, 375, 1829, 13, 118, 294, 1829, 5607, 800, 3726, 3726, 31, 22, 79, 699, 20, 3547, 375, 1829, 20, 21, 2741, 689, 13, 5, 472, 306, 9, 2328, 13, 118, 150, 5910, 100, 30, 1364, 21, 2841, 6, 29, 21, 5187, 16, 2150, 9, 31, 22, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What is the difference between a symbolic link and a hard link? === Recently I was asked this during a job interview. I was honest and said I knew how a symbolic link behaves and how to create one, but do not understand the use of a hard link and how it differs from a symbolic one.
0
[ 2, 98, 25, 14, 2841, 128, 21, 12882, 3508, 17, 21, 552, 3508, 60, 800, 3726, 3726, 1989, 31, 23, 411, 48, 112, 21, 1205, 2421, 9, 31, 23, 6964, 17, 87, 31, 404, 184, 21, 12882, 3508, 14149, 18, 17, 184, 20, 1600, 53, 15, 47,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
WeakReference and event handling === Is it a good practice to implement event handling through WeakReference if that event is the only thing holding the reference and that we would need the object to be garbage collected? As an argument to this: Folks say that if you subscribe to something it’s your responsibility to unsubscribe and you should do it.
0
[ 2, 3910, 28018, 17, 807, 7988, 800, 3726, 3726, 25, 32, 21, 254, 1345, 20, 8713, 807, 7988, 120, 3910, 28018, 100, 30, 807, 25, 14, 104, 584, 1337, 14, 2801, 17, 30, 95, 83, 376, 14, 3095, 20, 44, 15024, 3674, 60, 28, 40, 5476...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I create a copy of an object in PHP? === It appears that in PHP everything is passed by reference. Even assignment operators do not appear to be creating a copy of the Object. Here's a simple, contrived proof: <?php class A { public $b; } function set_b($obj) { $obj->b = "after"; } $a = new A(); $a->b = "before"; $c = $a; //i would especially expect this to create a copy. set_b($a); print $a->b; //i would expect this to show 'before' print $c->b; //i would ESPECIALLY expect this to show 'before' ?> In both print cases I am getting 'after' So, how do I pass **$a** to ***set_b()*** by value, not by reference?
0
[ 2, 184, 107, 31, 1600, 21, 4344, 16, 40, 3095, 19, 13, 26120, 60, 800, 3726, 3726, 32, 1780, 30, 19, 13, 26120, 796, 25, 1100, 34, 2801, 9, 166, 8427, 9475, 107, 52, 1893, 20, 44, 2936, 21, 4344, 16, 14, 3095, 9, 235, 22, 18...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Delete Folder Contents in Python === How can I delete the contents of a local folder in Python.<br /> The current project is for Windows but I would like to see *nix also.
0
[ 2, 27448, 19294, 8478, 19, 20059, 800, 3726, 3726, 184, 92, 31, 27448, 14, 8478, 16, 21, 375, 19294, 19, 20059, 9, 1, 5145, 13, 118, 1, 14, 866, 669, 25, 26, 1936, 47, 31, 83, 101, 20, 196, 1637, 14064, 67, 9, 3, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
Overriding the java equals() method quirk === I ran into an interesting (and very frustrating) issue with the equals() method today which caused what I thought to be a well tested class to crash and cause a bug that took me a very long time to track down. Just for completeness, I wasn't using an IDE or debugger - just good old fashioned text editor and System.out's. Time was very limited and it was a school project. Anyhow - I was developing a basic shopping cart which could contain an ArrayList of Book objects. In order to implement the addBook(), removeBook(), and hasBook() methods of the Cart, I wanted to check if the Book already existed in the cart. So off I go - public boolean equals(Book b) { ... // More code here - null checks if (b.getID() == this.getID()) return true; else return false; } All works fine in testing. I create 6 objects and fill them with data. Do many adds, removes, has() operations on the Cart and everything works fine. I read that you can either have equals(TYPE var) or equals(Object o) { (CAST) var } but assumed that since it was working, it didn't matter too much. Then I ran into a problem - I needed to create a Book object with only the ID in it from within the Book class. No other data would be entered into it. Basically the following: public boolean hasBook(int i) { Book b = new Book(i); return hasBook(b); } public boolean hasBook(Book b) { // .. more code here return this.equals(b); } All of a sudden, the equals(Book b) method no longer works. This took a VERY long time to track down without a good debugger and assuming the Cart class was properly tested and correct. After swaapping the equals() method to the following: public boolean equals(Object o) { Book b = (Book) o; ... // The rest goes here } Everything began to work again. Is there a reason the method decided not to take the Book parameter even though it clearly <b> was </b> a Book object? The only difference seemed to be it was instantiated from within the same class, and only filled with one data member. I'm very very confused. Please, shed some light?
0
[ 2, 84, 5175, 68, 14, 8247, 2747, 18, 5, 6, 2109, 19321, 800, 3726, 3726, 31, 717, 77, 40, 4883, 13, 5, 290, 253, 25568, 6, 1513, 29, 14, 2747, 18, 5, 6, 2109, 786, 56, 1497, 98, 31, 289, 20, 44, 21, 134, 7631, 718, 20, 459...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Ruby: define_method vs. def === As a programming exercise, I've written a Ruby snippet that creates a class, instantiates two objects from that class, monkeypatches one object, and relies on method_missing to monkeypatch the other one. Here's the deal. This works as intended: class Monkey def chatter puts "I am a chattering monkey!" end def method_missing(m) puts "No #{m}, so I'll make one..." def screech puts "This is the new screech." end end end m1 = Monkey.new m2 = Monkey.new m1.chatter m2.chatter def m1.screech puts "Aaaaaargh!" end m1.screech m2.screech m2.screech m1.screech m2.screech You'll notice that I have a parameter for method_missing. I did this because I was hoping to use define_method to dynamically create missing methods with the appropriate name. However, it doesn't work. In fact, even using define_method with a static name like so: def method_missing(m) puts "No #{m}, so I'll make one..." define_method(:screech) do puts "This is the new screech." end end Ends with the following result: ArgumentError: wrong number of arguments (2 for 1) method method_missing in untitled document at line 9 method method_missing in untitled document at line 9 at top level in untitled document at line 26 Program exited. What makes the error message more bewildering is that I only have one argument for method_missing... Any help would be appreciated. Thank you.
0
[ 2, 10811, 45, 9267, 1, 5909, 1807, 43, 4611, 9, 6312, 800, 3726, 3726, 28, 21, 3143, 5935, 15, 31, 22, 195, 642, 21, 10811, 13, 29061, 30, 9695, 21, 718, 15, 6322, 15882, 18, 81, 3916, 37, 30, 718, 15, 11861, 23661, 160, 53, 3...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How Do I Detect the Adobe Acrobat Version Installed in Firefox via JavaScript === Title says it all. I know this can be done in IE by creating an ActiveX object, but how do I do it in FF. The navigator.plugins['Adobe Acrobat'] object lets me know if it's installed or not, but it doesn't contain the version number. Any ideas?
0
[ 2, 184, 107, 31, 9092, 14, 20299, 21, 7638, 4900, 615, 4066, 19, 535, 18219, 1197, 8247, 8741, 800, 3726, 3726, 581, 898, 32, 65, 9, 31, 143, 48, 92, 44, 677, 19, 13, 660, 34, 2936, 40, 1348, 396, 3095, 15, 47, 184, 107, 31, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Can I pass a sharepoint security context value to a reporting services report parameter? === I'm considering using reporting services 05 SP2 with share point integration on a new reporting project. In this project's reports users can only see records they own. I was thinking a simple userId parameter on the report would allow me to filter the report's results to only these "owned" records. I'm curious: Can I pass the current share point user's ID to the report some how? Can it be done in such a way that its not possible for the user to somehow alter it? How would I do this if possible?
0
[ 2, 92, 31, 1477, 21, 1891, 3132, 1221, 4141, 1923, 20, 21, 6670, 687, 1330, 18906, 60, 800, 3726, 3726, 31, 22, 79, 5154, 568, 6670, 687, 13, 4071, 3782, 135, 29, 1891, 454, 8078, 27, 21, 78, 6670, 669, 9, 19, 48, 669, 22, 18,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I send an alert to a blackberry from an Excel 2007 spreadsheet? === I've been asked to find a way to send an alert to a blackberry when certain conditions are met on an Excel 2007 spreadsheet. The alert can be an SMS (preferred) or an email. The cell values are changing throughout the day from a DDE feed. What are the typical solutions that people use to solve this?
0
[ 2, 184, 107, 31, 2660, 40, 7863, 20, 21, 27367, 37, 40, 20700, 624, 1789, 17627, 60, 800, 3726, 3726, 31, 22, 195, 74, 411, 20, 477, 21, 161, 20, 2660, 40, 7863, 20, 21, 27367, 76, 1200, 2039, 50, 798, 27, 40, 20700, 624, 1789...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I change the title of a page in rails? === What is the best why to create a custom title for pages in a rails' app with out using a plug-in?
0
[ 2, 184, 107, 31, 753, 14, 581, 16, 21, 2478, 19, 2240, 18, 60, 800, 3726, 3726, 98, 25, 14, 246, 483, 20, 1600, 21, 5816, 581, 26, 4434, 19, 21, 2240, 18, 22, 4865, 29, 70, 568, 21, 10922, 8, 108, 60, 3, 0, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
How to select a range of elements in jQuery. === <div id="myDiv"> <a>...</a> <a>...</a> <a>...</a> <a>...</a> <a>...</a> <a>...</a> </div> If you wanted to select the 2nd, 3rd and 4th `a` tags in the above example, how would you do that? The only thing I can think of is: $("#myDiv a:eq(1), #myDiv a:eq(2), #myDiv a:eq(3)") But that doesn't look to be very efficient or pretty. I guess you could also select ALL the `a`s and then do run `.each` over them, but that could get very inefficient if there were a lot more `a`s.
0
[ 2, 184, 20, 5407, 21, 978, 16, 2065, 19, 487, 8190, 93, 9, 800, 3726, 3726, 13, 1, 12916, 4924, 3726, 7, 915, 12916, 7, 1, 13, 1, 58, 1, 9, 9, 9, 1, 118, 58, 1, 13, 1, 58, 1, 9, 9, 9, 1, 118, 58, 1, 13, 1, 58, 1, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Generate an E-R Diagram from a PostgreSQL Database === Querying PostgreSQL data dictionary for foreign-keys and relationship between tables is very straightforward, but how can I use that information to generate a graph of the relations between tables? Any recommendations about tools that can do this?
0
[ 2, 7920, 40, 13, 62, 8, 139, 14161, 37, 21, 678, 6879, 18, 22402, 6018, 800, 3726, 3726, 25597, 68, 678, 6879, 18, 22402, 1054, 9186, 26, 1228, 8, 4237, 18, 17, 1429, 128, 7484, 25, 253, 22262, 15, 47, 184, 92, 31, 275, 30, 67...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
"Arrays" in Scala === In javascript, we can do: ["a string", 10, {x : 1}, function() {}].push("another value"); What is the Scala equivalent?
0
[ 2, 13, 7, 8576, 93, 18, 7, 19, 25975, 800, 3726, 3726, 19, 8247, 8741, 15, 95, 92, 107, 45, 636, 7, 58, 3724, 7, 15, 332, 15, 13, 1, 396, 13, 45, 137, 1, 15, 1990, 5, 6, 13, 1, 500, 9, 26973, 5, 7, 14945, 1923, 7, 6, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0...
Configuring IIS on Windows Vista Home Edition === My friend accidentally bought a laptop with Windows Vista Home Edition. He figured out how to install IIS on it, but it doesn't seem to have either the management console or the admin tools. Is there any way for him to configure a site or import an IIS 6 config file?
0
[ 2, 1065, 13549, 68, 595, 18, 27, 1936, 13520, 213, 1322, 800, 3726, 3726, 51, 860, 9746, 2448, 21, 12294, 29, 1936, 13520, 213, 1322, 9, 24, 5700, 70, 184, 20, 16146, 595, 18, 27, 32, 15, 47, 32, 1437, 22, 38, 2260, 20, 57, 69...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What open source .Net utility projects or code libraries do you use? === I use log4net in just about every code project. I was wondering what other generally useful code projects are available?
0
[ 2, 98, 368, 1267, 13, 9, 2328, 10082, 2314, 54, 1797, 8649, 107, 42, 275, 60, 800, 3726, 3726, 31, 275, 6738, 300, 2328, 19, 114, 88, 352, 1797, 669, 9, 31, 23, 5712, 98, 89, 1469, 4811, 1797, 2314, 50, 904, 60, 3, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
Winforms - MVP examples === Does anyone have a good example code or test project for explaining someone MVP pattern. There are a lot of explanation links but i want to have some good example code to show others without reinventing the wheel.
0
[ 2, 628, 4190, 18, 13, 8, 13552, 3770, 800, 3726, 3726, 630, 1276, 57, 21, 254, 823, 1797, 54, 1289, 669, 26, 10225, 737, 13552, 3732, 9, 80, 50, 21, 865, 16, 5764, 6271, 47, 31, 259, 20, 57, 109, 254, 823, 1797, 20, 298, 654, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
How do I listen/identify when a program runs in Windows using C++? === Specifically, I want to listen to when programs are run and record information such as: timestamp, executable, windows name and user.
0
[ 2, 184, 107, 31, 3834, 118, 13384, 8612, 76, 21, 625, 1461, 19, 1936, 568, 272, 20512, 60, 800, 3726, 3726, 3524, 15, 31, 259, 20, 3834, 20, 76, 1726, 50, 485, 17, 571, 676, 145, 28, 45, 436, 38, 10158, 15, 1396, 17194, 5924, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
What is the best language construction in C#? === What is the best language construction you have worked with in C#. One of my favorites is Generics.
4
[ 2, 98, 25, 14, 246, 816, 900, 19, 272, 5910, 60, 800, 3726, 3726, 98, 25, 14, 246, 816, 900, 42, 57, 577, 29, 19, 272, 5910, 9, 53, 16, 51, 3839, 18, 25, 12733, 18, 9, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
What's the best way to find a string/regex match in files recursively? (UNIX) === I have had to do this several times, usually when trying to find in what files a variable or a function is used. I remember using xargs with grep in the past to do this, but I am wondering if there are any easier ways.
0
[ 2, 98, 22, 18, 14, 246, 161, 20, 477, 21, 3724, 118, 12463, 1706, 730, 19, 6488, 302, 24244, 102, 60, 13, 5, 1020, 4028, 6, 800, 3726, 3726, 31, 57, 41, 20, 107, 48, 238, 436, 15, 951, 76, 749, 20, 477, 19, 98, 6488, 21, 7...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do you explain this structure in javascript === (function() { //codehere } )(); what is special about this kind of syntax? what does ()(); imply?
0
[ 2, 184, 107, 42, 3271, 48, 1411, 19, 8247, 8741, 800, 3726, 3726, 13, 5, 22359, 5, 6, 13, 1, 12894, 9375, 6836, 13, 1, 13, 6, 5, 6, 73, 98, 25, 621, 88, 48, 825, 16, 22649, 60, 98, 630, 13, 5, 6, 5, 6, 73, 21679, 60, 3...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
Is it possible to print a DIV that is hidden by JQuery's "slideUp" function. === I have a simple "accordion" type page containing a list of H3 headers and DIV content boxes (each H3 is followed by a DIV). On this page I start with all DIVs hidden. When a H3 is clicked the DIV directly below (after) is revealed with JQuery's ["slideDown"][1] function while all other DIVs are hidden with the ["slideUp"][2] function. The "slideUp" function inserts the following inline style into the specified DIVs: style="display: none;" I am wondering if there is any way for me to show all the DIVs expanded when a user prints the page (as I do when a user has JavaScript disabled). I am thinking it is impossible because the inline style will always take precedence over any other style declaration. Is there another solution? [1]: http://jquery.com/api/#slideDown [2]: http://jquery.com/api/#slideUp
0
[ 2, 25, 32, 938, 20, 4793, 21, 13, 12916, 30, 25, 3689, 34, 487, 8190, 93, 22, 18, 13, 7, 18, 1210, 546, 576, 7, 1990, 9, 800, 3726, 3726, 31, 57, 21, 1935, 13, 7, 22301, 897, 872, 7, 1001, 2478, 3503, 21, 968, 16, 746, 240...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Is there any way to validate the width and height of image when uploaded? === Is there any way to validate the width and height of image when uploaded? using javascript of server side ? like jsp, aspx etc?
0
[ 2, 25, 80, 186, 161, 20, 7394, 1373, 14, 9456, 17, 2947, 16, 1961, 76, 23782, 60, 800, 3726, 3726, 25, 80, 186, 161, 20, 7394, 1373, 14, 9456, 17, 2947, 16, 1961, 76, 23782, 60, 568, 8247, 8741, 16, 8128, 270, 13, 60, 101, 487...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
Is it considered bad practise to use absolute positioning? === I was developing a web page, where I was laying out a board for a Chess-like game, along with a couple of piece trays. It's all done using HTML (with jQuery for dynamic updating as the game is played). Somewhere I'd got the notion that using absolute positioning of elements within a page was considered a bad practice, and that it was preferable to use relative positioning. After struggling with relative positioning for too long, I realised that absolute positioning of the board elements would be much, much easier to get right... and it was. Is anyone aware of a reason that relative positioning is preferable over relative? Are there any guidelines or rules of thumb that you apply when deciding which approach to take?
0
[ 2, 25, 32, 724, 896, 27954, 20, 275, 7070, 649, 68, 60, 800, 3726, 3726, 31, 23, 3561, 21, 2741, 2478, 15, 113, 31, 23, 11514, 70, 21, 686, 26, 21, 6168, 8, 1403, 250, 15, 303, 29, 21, 1335, 16, 1855, 10121, 18, 9, 32, 22, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Can an ASP.Net MVC controller return an Image? === Can I create a Controller that simply returns an image asset? I would like to route this logic through a controller, whenever a url such as the following is requested: www.mywebsite.com/resource/image/topbanner The controller will look up "topbanner.png" and send that image directly back to the client. I've seen examples of this where you have to create a View -- I don't want to use a View. I want to do it all with just the Controller. Is this possible?
0
[ 2, 92, 40, 28, 306, 9, 2328, 307, 8990, 9919, 788, 40, 1961, 60, 800, 3726, 3726, 92, 31, 1600, 21, 9919, 30, 1659, 4815, 40, 1961, 12146, 60, 31, 83, 101, 20, 858, 48, 7085, 120, 21, 9919, 15, 6634, 21, 287, 6362, 145, 28, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What's is a good ratio of Class to Lines of Code for Object-Oriented languages? === What's is a good ratio for the number Classes to Lines of Code for an Object-Oriented language (say C++,C#,Java and their likes)? Many people, including managers, like the traditional LOC (lines of code) metric to measure the complexity of software, while many hard-boiled Object Oriented developers will say LOC is worthless its Class count that matters. And personally I believe that Classes may be a more reasonable metric of complexity, but that without a LOC metric the actual complexity of those classes (amount of poltergeists and gods in there) is hard to estimate. Thus does anybody know of what is likely to be a healthy ratio for some fairly well coded software?
0
[ 2, 98, 22, 18, 25, 21, 254, 4825, 16, 718, 20, 1560, 16, 1797, 26, 3095, 8, 6800, 2556, 60, 800, 3726, 3726, 98, 22, 18, 25, 21, 254, 4825, 26, 14, 234, 2684, 20, 1560, 16, 1797, 26, 40, 3095, 8, 6800, 816, 13, 5, 6366, 27...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Left Join outperforming Inner Join? === I've been profiling some queries in an application I'm working on, and I came across a query that was retrieving more rows than necessary, the result set being trimmed down in the application code. Changing a LEFT JOIN to an INNER JOIN trimmed the result set to just what was needed, and presumably would also be more performant (since less rows are selected). In reality, the LEFT JOIN'ed query was outperforming the INNER JOIN'ed, taking half the time to complete. LEFT JOIN: (127 total rows, Query took 0.0011 sec) INNER JOIN: (10 total rows, Query took 0.0024 sec) (I ran the queries multiple times and those are averages). Running EXPLAIN on both reveals nothing that explains the performance differences: For the INNER JOIN: id select_type table type possible_keys key key_len ref rows Extra 1 SIMPLE contacts index NULL name 302 NULL 235 Using where 1 SIMPLE lists eq_ref PRIMARY PRIMARY 4 contacts.list_id 1 1 SIMPLE lists_to_users eq_ref PRIMARY PRIMARY 8 lists.id,const 1 1 SIMPLE tags eq_ref PRIMARY PRIMARY 4 lists_to_users.tag_id 1 1 SIMPLE users eq_ref email_2 email_2 302 contacts.email 1 Using where For the LEFT JOIN: id select_type table type possible_keys key key_len ref rows Extra 1 SIMPLE contacts index NULL name 302 NULL 235 Using where 1 SIMPLE lists eq_ref PRIMARY PRIMARY 4 contacts.list_id 1 1 SIMPLE lists_to_users eq_ref PRIMARY PRIMARY 8 lists.id,const 1 1 SIMPLE tags eq_ref PRIMARY PRIMARY 4 lists_to_users.tag_id 1 1 SIMPLE users eq_ref email_2 email_2 302 contacts.email 1 And the query itself: SELECT `contacts`.*, `lists`.`name` AS `group`, `lists`.`id` AS `group_id`, `lists`.`shared_yn`, `tags`.`name` AS `context`, `tags`.`id` AS `context_id`, `tags`.`color` AS `context_color`, `users`.`id` AS `user_id`, `users`.`avatar` FROM `contacts` LEFT JOIN `lists` ON lists.id=contacts.list_id LEFT JOIN `lists_to_users` ON lists_to_users.list_id=lists.id AND lists_to_users.user_id='1' AND lists_to_users.creator='1' LEFT JOIN `tags` ON tags.id=lists_to_users.tag_id INNER JOIN `users` ON users.email=contacts.email WHERE (contacts.user_id='1') ORDER BY `contacts`.`name` ASC (The clause that I'm talking about is the last INNER JOIN on the 'users' table) The query runs on a MySQL 5.1 database, if it makes a difference. Does anyone has a clue on why the LEFT JOIN'ed query outperforms the INNER JOIN'ed on in this case?
0
[ 2, 225, 1865, 70, 1432, 12362, 3754, 1865, 60, 800, 3726, 3726, 31, 22, 195, 74, 8721, 49, 802, 109, 9386, 2829, 19, 40, 3010, 31, 22, 79, 638, 27, 15, 17, 31, 281, 464, 21, 25597, 30, 23, 13, 6239, 3272, 8397, 91, 11295, 119,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What are some good DirectX resources for a beginner? === I'm learning DirectX as part of a hobby project. I've been looking for some good online resources for DirectX9 (using C++, if that distinction matters), but haven't found anything that's a) great for a beginner and b) up to date. Any recommendations?
0
[ 2, 98, 50, 109, 254, 1744, 396, 2566, 26, 21, 26931, 60, 800, 3726, 3726, 31, 22, 79, 2477, 1744, 396, 28, 141, 16, 21, 18229, 669, 9, 31, 22, 195, 74, 699, 26, 109, 254, 2087, 2566, 26, 1744, 396, 518, 13, 5, 12655, 272, 20...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I create a sparse file programmatically, in C, on Mac OS X? === I'd like to create a sparse file such that all-zero blocks don't take up actual disk space until I write data to them. Is it possible?
0
[ 2, 184, 107, 31, 1600, 21, 23162, 3893, 625, 6732, 1326, 15, 19, 272, 15, 27, 1572, 13, 759, 993, 60, 800, 3726, 3726, 31, 22, 43, 101, 20, 1600, 21, 23162, 3893, 145, 30, 65, 8, 15938, 5198, 221, 22, 38, 247, 71, 3463, 8582, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0...
Initializing static objects - Code design question === In my webapplication (C#, .Net 3.5), made up of a *core* class library (containing the business logic, data layer and a couple of utility classes), a windows service project, a webservice project and the website project, I have a couple of static classes in the *core* library used by all other projects. These classes (for example the **Log** class) require some initialization (They have an **Initialize** method) in order to set them up for usage. As an example, the **Initialize** method of the **Log** class has a directory path parameter which tells the **Log**, where to save the logfiles to. Alternativly I was thinking of loading the "settings" for the **Log** class from a configuration file in the static constructor. The drawback is, that I need different settings for unit-testing then in production code. Is there a better way to design this? The drawback of this approach is, that all consumers of the static class will attempt to call Initialize. This is not really a problem because once initialized, the method will return immediately instead of executing the Initialize code again, but the design seems a bit weird to me. I hope my english is sufficient to explain what I'm after. Do not hesitate to ask if the question is not clear enough.
0
[ 2, 2104, 3335, 12038, 3916, 13, 8, 1797, 704, 1301, 800, 3726, 3726, 19, 51, 2741, 2552, 20669, 13, 5, 150, 5910, 15, 13, 9, 2328, 203, 9, 264, 6, 15, 117, 71, 16, 21, 1637, 10375, 2483, 718, 1248, 13, 5, 26425, 14, 508, 7085,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do you add a timer to a C# console application === Just this - How do you add a timer to a C# console application?
0
[ 2, 184, 107, 42, 3547, 21, 85, 139, 20, 21, 272, 5910, 8650, 3010, 800, 3726, 3726, 114, 48, 13, 8, 184, 107, 42, 3547, 21, 85, 139, 20, 21, 272, 5910, 8650, 3010, 60, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
How many rows can an SQLite table hold before queries become time comsuming === I'm setting up a simple SQLite database to hold sensor readings. The tables will look something like this: sensors - id (pk) - name - description - units sensor_readings - id (pk) - sensor_id (fk to sensors) - value (actual sensor value stored here) - time (date/time the sensor sample was taken) The application will be capturing about 100,000 sensor readings per month from about 30 different sensors, and I'd like to keep all sensor readings in the DB as long as possible. Most queries will be in the form SELECT * FROM sensor_readings WHERE sensor_id = x AND time > y AND time < z This query will usually return about 100-1000 results. So the question is, how big can the sensor_readings table get before the above query becomes too time consuming (more than a couple seconds on a standard PC). I know that one fix might be to create a separate sensor_readings table for each sensor, but I'd like to avoid this if it is unnecessary. Are there any other ways to optimize this DB schema?
0
[ 2, 184, 151, 11295, 92, 40, 4444, 10601, 859, 1027, 115, 9386, 2829, 533, 85, 13, 960, 18, 723, 68, 800, 3726, 3726, 31, 22, 79, 2697, 71, 21, 1935, 4444, 10601, 6018, 20, 1027, 14865, 1876, 18, 9, 14, 7484, 129, 361, 301, 101, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Regex Search & Replace Program === Is there a simple and lightweight program to search over a text file and replace a string with regex?
0
[ 2, 7953, 1706, 2122, 279, 3934, 625, 800, 3726, 3726, 25, 80, 21, 1935, 17, 13613, 625, 20, 2122, 84, 21, 1854, 3893, 17, 3934, 21, 3724, 29, 7953, 1706, 60, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
How do you handle the "Too many files" problem when working in Bash? === I many times have to work with directories containing hundreds of thousands of files, doing text matching, replacing and so on. If I go the standard route of, say grep foo * I get the too many files error message, so I end up doing for i in *; do grep foo $i; done or find ../path/ | xargs -I{} grep foo "{}" But these are less than optimal (create a new grep process per each file). This looks like more of a limitation in the size of the arguments programs can receive, because the * in the for loop works alright. But, in any case, what's the proper way to handle this? PS: Don't tell me to do grep -r instead, I know about that, I'm thinking about tools that do not have a recursive option.
0
[ 2, 184, 107, 42, 3053, 14, 13, 7, 8175, 151, 6488, 7, 1448, 76, 638, 19, 13158, 60, 800, 3726, 3726, 31, 151, 436, 57, 20, 170, 29, 559, 1596, 3503, 4541, 16, 3805, 16, 6488, 15, 845, 1854, 10120, 15, 5496, 17, 86, 27, 9, 10...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do you use environment variables in vxWorks? === In a vxWorks Real-Time process, you can pass environment variables as one of the parameter of the **main** routine. How do you use the environment variables in the kernel context?
0
[ 2, 184, 107, 42, 275, 2307, 12157, 19, 566, 396, 7684, 60, 800, 3726, 3726, 19, 21, 566, 396, 7684, 683, 8, 891, 953, 15, 42, 92, 1477, 2307, 12157, 28, 53, 16, 14, 18906, 16, 14, 13, 1409, 6232, 1409, 8275, 9, 184, 107, 42, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0...
Eclipse fonts and background color === I have been trying to change the background color of eclipses windows to black and customize the font colors. There doesn't seem to be a way to do this at least not an obvious way. I am using version 3.3. Does anyone know how to do this or of any plugin's that might be able to assist in doing this?
0
[ 2, 11652, 9978, 18, 17, 2395, 1665, 800, 3726, 3726, 31, 57, 74, 749, 20, 753, 14, 2395, 1665, 16, 11652, 18, 1936, 20, 319, 17, 5816, 2952, 14, 9978, 5268, 9, 80, 1437, 22, 38, 2260, 20, 44, 21, 161, 20, 107, 48, 35, 639, 5...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What to do if I don't have Visual Basic 6.0 and need to compile a VB6 project? === A client wants me to do some maintenance work to a VB 6.0 application (migration to .NET is also in the pipeline), but he doesn't have the development tools because he received just the source code and running application from the original programmer, who is no longer available. Microsoft doesn't sell Visual Studio 6.0, as far as I know. **How can I modify and compile the source code for a VB6 application without VB6?** or **Where do I get Visual Studio 6.0 if Microsoft is not selling it?.** Even if I migrate everything to .NET without releasing a new VB6 version, I would like to be able to open the project and see it compile and run to better understand it. I have VS 2005 and VB 2008. But I understand that if I try to open the project the code will be converted to VB.NET and that's not what I would want before getting to know the project better.
0
[ 2, 98, 20, 107, 100, 31, 221, 22, 38, 57, 3458, 2125, 400, 9, 387, 17, 376, 20, 26561, 21, 13, 20468, 379, 669, 60, 800, 3726, 3726, 21, 6819, 2846, 55, 20, 107, 109, 5010, 170, 20, 21, 13, 20468, 400, 9, 387, 3010, 13, 5, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Extracting unique items from a list of mappings === He're an interesting problem that looks for the most Pythonic solution. Suppose I have a list of mappings `{'id': id, 'url': url}`. Some `id`s in the list are duplicate, and I want to create a new list, with all the duplicates removed. I came up with the following function: def unique_mapping(map): d = {} for res in map: d[res['id']] = res['url'] return [{'id': id, 'url': d[id]} for id in d] I suppose it's quite efficient. But is there a "more Pythonic" way ? Or perhaps a more efficient way ?
0
[ 2, 10962, 68, 2619, 3755, 37, 21, 968, 16, 13305, 18, 800, 3726, 3726, 24, 22, 99, 40, 4883, 1448, 30, 1879, 26, 14, 127, 20059, 596, 4295, 9, 5787, 31, 57, 21, 968, 16, 13305, 18, 13, 1, 22, 1340, 22, 45, 4924, 15, 13, 22, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
MVC data design problem with Zend framework. === If I have a class representing access to one table in my database in a class:table relationship, so I can hide table details in one class. But as any useful application I have to query several tables. How can I accomodate this using the class:table design?
0
[ 2, 307, 8990, 1054, 704, 1448, 29, 10526, 43, 6596, 9, 800, 3726, 3726, 100, 31, 57, 21, 718, 3793, 1381, 20, 53, 859, 19, 51, 6018, 19, 21, 718, 45, 5924, 1429, 15, 86, 31, 92, 3077, 859, 3289, 19, 53, 718, 9, 47, 28, 186, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I add to a list with Linq to SQL? === I have a table in the database that I'm retrieving using LINQ to SQL, and as a part of my processing I want to add to this list, then update the database with the new items + any changes I've made. What I thought I could do was this: var list = (from item in db.Table select item).ToList(); [do processing where I modify items & add to the list] list = list.Distinct(); db.SubmitChanges(); What happens is that the modifications happed (ie. SQL updates) but any new items I add to the list don't get added. Obviously I'm doing this wrong, what is the correct way to modify & add to a list of DB entities, then commit all the updates & inserts?
0
[ 2, 184, 107, 31, 3547, 20, 21, 968, 29, 6294, 1251, 20, 4444, 255, 60, 800, 3726, 3726, 31, 57, 21, 859, 19, 14, 6018, 30, 31, 22, 79, 13, 6239, 3272, 8397, 568, 6294, 1251, 20, 4444, 255, 15, 17, 28, 21, 141, 16, 51, 5511, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What is your method to generate Websphere 6 EJB with Ant / JDK 1.4.x ? === The only working method I found, several years ago, was : 1. Generating ibm-ejb-jar-bnd.xmi and ibm-ejb-jar-ext.xmi for each session bean by using XDoclet (ejbdoclet task) 2. Making a jar (without stubs) with task jar; ; 3. Calling the binary EJBDEPLOY with this jar without stub in parameters. But I feel there must be a cleaner method. Which is yours ?
0
[ 2, 98, 25, 154, 2109, 20, 7920, 2741, 14079, 400, 13, 10022, 220, 29, 40, 38, 13, 118, 487, 43, 197, 137, 9, 300, 9, 396, 13, 60, 800, 3726, 3726, 14, 104, 638, 2109, 31, 216, 15, 238, 122, 1464, 15, 23, 13, 45, 137, 9, 13...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
SQL 2005 Full-Text Catalog is randomly sloooowww === I've built a full-text catalog on a SQL 2005 box that, after it's re-build process completes, runs extremely slow. I've implemented a hack (i.e. try...catch{do again}) so that my users don't get a timeout error; this makes me feel bad inside. Has anyone experienced this issue and was/is there a solution? Thanks! P.S. Yes, I've Google'd it many times. Even with my left hand.
0
[ 2, 4444, 255, 812, 503, 8, 11969, 10594, 25, 21324, 13718, 28290, 6483, 800, 3726, 3726, 31, 22, 195, 392, 21, 503, 8, 11969, 10594, 27, 21, 4444, 255, 812, 1649, 30, 15, 75, 32, 22, 18, 302, 8, 29361, 953, 1279, 18, 15, 1461, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What project files shouldn't be checked into SVN === At the moment I check in all my files (including dll's, VS solution files, images, etc). I often need to checkout these files to a staging server or to a another developer and so having these files there means the project is setup there all ready to go. Whats the best practice here?
0
[ 2, 98, 669, 6488, 5714, 22, 38, 44, 6505, 77, 13, 18, 16578, 800, 3726, 3726, 35, 14, 688, 31, 2631, 19, 65, 51, 6488, 13, 5, 3970, 13, 43, 211, 22, 18, 15, 4611, 4295, 6488, 15, 3502, 15, 2722, 6, 9, 31, 478, 376, 20, 263...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What is the best way to open a file for exclusive access in Python? === What is the most elegant way to solve this: - open a file for reading, but only if it is not already opened for writing - open a file for writing, but only if it is not already opened for reading or writing The built-in functions work like this >>> path = r"c:\scr.txt" >>> file1 = open(path, "w") >>> print file1 <open file 'c:\scr.txt', mode 'w' at 0x019F88D8> >>> file2 = open(path, "w") >>> print file2 <open file 'c:\scr.txt', mode 'w' at 0x02332188> >>> file1.write("111") >>> file2.write("222") >>> file1.close() scr.txt now contains '111'. >>> file2.close() scr.txt was overwritten and now contains '222' (on Windows, Python 2.4).
0
[ 2, 98, 25, 14, 246, 161, 20, 368, 21, 3893, 26, 6753, 1381, 19, 20059, 60, 800, 3726, 3726, 98, 25, 14, 127, 11614, 161, 20, 8402, 48, 45, 13, 8, 368, 21, 3893, 26, 1876, 15, 47, 104, 100, 32, 25, 52, 614, 520, 26, 1174, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Visual Studio 6 Processor Pack compatibility === I've seen that a Processor Pack is available for Visual Studio 6, however it appears to only be available for users with SP5 and I am already using SP6. Firstly, is this processor pack compatible with Visual Studio 6 SP6? Secondly, would it actually help me? I'm concerned about getting the most from my application, but it needs to run on all flavours of Intel and AMD chips so I can't just target one platform.
0
[ 2, 3458, 1120, 400, 14762, 3607, 13, 21618, 800, 3726, 3726, 31, 22, 195, 541, 30, 21, 14762, 3607, 25, 904, 26, 3458, 1120, 400, 15, 207, 32, 1780, 20, 104, 44, 904, 26, 3878, 29, 3782, 264, 17, 31, 589, 614, 568, 3782, 379, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Latex styles - what do you use and where to find them === What Latex styles do you use and where do you find them? The reason I'm asking this is that it seems that some 99.9999% of all styles on the internet are copies of each other and of a [physics exam paper][1] However, when you try to find a style for a paper like [this one][2]... Good luck, you are never going to find it. Creating your own style is often not really an option, because it requires you to dig quite deep into the very advanced features of TeX/LaTeX and fighting your way against possible incompatibilities with document classes/packages/whatnot. [1]: http://www.tug.org/texshowcase/ps_s_1b.pdf [2]: http://www.tug.org/texshowcase/en_gb_eclipse_114.pdf
0
[ 2, 456, 396, 6443, 13, 8, 98, 107, 42, 275, 17, 113, 20, 477, 105, 800, 3726, 3726, 98, 456, 396, 6443, 107, 42, 275, 17, 113, 107, 42, 477, 105, 60, 14, 1215, 31, 22, 79, 3379, 48, 25, 30, 32, 2206, 30, 109, 7787, 9, 2317...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Run time error in ASP.Net 1.1 === I am using Windows 2003. I have mapped a web application into a virtual directory. This is built on framework 1.1 When i try to browse to the default page i get a error as Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately. Parser Error Message: Access is denied: 'Interop.MSDASC'. Source Error: Line 196: <add assembly="System.EnterpriseServices, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/> Line 197: <add assembly="System.Web.Mobile, Version=1.0.5000.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a"/> Line 198: <add assembly="*"/> Line 199: </assemblies> Line 200: </compilation> Source File: c:\windows\microsoft.net\framework\v1.1.4322\Config\machine.config Line: 198 Assembly Load Trace: The following information can be helpful to determine why the assembly 'Interop.MSDASC' could not be loaded.
0
[ 2, 485, 85, 7019, 19, 28, 306, 9, 2328, 137, 9, 165, 800, 3726, 3726, 31, 589, 568, 1936, 973, 9, 31, 57, 20877, 21, 2741, 3010, 77, 21, 6599, 16755, 9, 48, 25, 392, 27, 6596, 137, 9, 165, 76, 31, 1131, 20, 10175, 62, 20, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
In WPF Style, How can Trigger access a son Element of the Element it is attatched === The following is a Simple Style for ListBoxItem, ListBoxItem has a son Border. Border has a Padding property with value of 8, I want to change the value to 0, when the item is selected. How can I write the trigger? <??Style TargetType="{x:Type ListBoxItem}"> <Setter Property="Background" Value="Transparent" /> <Setter Property="Template"> <Setter.Value> <ControlTemplate TargetType="{x:Type ListBoxItem}" > <Border SnapsToDevicePixels="True" HorizontalAlignment="Center" VerticalAlignment="Center" Padding = "8" Background="{TemplateBinding Background}"> <ContentPresenter /> </Border> <ControlTemplate.Triggers> <Trigger Property="IsSelected" Value="True"> ??<Setter Property="Padding" Value="0" />?? <----How Can I do this? </Trigger> </ControlTemplate.Triggers> </ControlTemplate> </Setter.Value> </Setter> <??/Style>
0
[ 2, 19, 619, 7721, 1034, 15, 184, 92, 7286, 1381, 21, 433, 4520, 16, 14, 4520, 32, 25, 35, 536, 38, 6261, 800, 3726, 3726, 14, 249, 25, 21, 1935, 1034, 26, 968, 5309, 2119, 79, 15, 968, 5309, 2119, 79, 63, 21, 433, 1862, 9, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Is EPiServer threadsafe? === I can't find any information about this on either www.episerver.com or world.episerver.com, anyone knows?
0
[ 2, 25, 5971, 10321, 106, 9322, 18166, 60, 800, 3726, 3726, 31, 92, 22, 38, 477, 186, 676, 88, 48, 27, 694, 13, 6483, 9, 3492, 13042, 2304, 9, 960, 54, 126, 9, 3492, 13042, 2304, 9, 960, 15, 1276, 3620, 60, 3, 0, 0, 0, 0, 0...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
NHibernate bidirectional many-to-many association === I have a class with following description: public class Customer { public ISet<Client> Contacts { get; protected set;} } I want to map Contacts property onto following table: CREATE TABLE user_contacts ( user1 uuid NOT NULL, user2 uuid NOT NULL, ) I want it to map bidirectionally, i.e. when Customer1 added to Customer2's Contacts, Customer1's Contacts collection should contain Customer2 (maybe only after entity reload). How could I do that?
0
[ 2, 12109, 15191, 8820, 1732, 19393, 151, 8, 262, 8, 14842, 607, 800, 3726, 3726, 31, 57, 21, 718, 29, 249, 5318, 45, 317, 718, 7705, 13, 1, 317, 25, 1198, 1, 150, 18513, 38, 1, 11894, 13, 1, 164, 73, 3803, 309, 73, 1, 13, 1,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Exporting DLL C++ Class , question about .def file === I want to use implicit linking in my project , and nmake really wants a .def file . The problem is , that this is a class , and I don't know what to write in the exports section . Could anyone point me in the right direction ? P.S: I'm trying to build using Windows CE Platform Builder .
0
[ 2, 7487, 68, 13, 43, 211, 272, 20512, 718, 13, 15, 1301, 88, 13, 9, 13862, 3893, 800, 3726, 3726, 31, 259, 20, 275, 20290, 12585, 19, 51, 669, 13, 15, 17, 13, 103, 11115, 510, 2846, 21, 13, 9, 13862, 3893, 13, 9, 14, 1448, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Easy IIS install of php === Are there any "all-in-one" installers for php + mysql on iis? Preferably with a gui configuration interface.
0
[ 2, 2010, 595, 18, 16146, 16, 13, 26120, 800, 3726, 3726, 50, 80, 186, 13, 7, 1233, 8, 108, 8, 849, 7, 16146, 445, 26, 13, 26120, 2754, 51, 18, 22402, 27, 595, 18, 60, 6369, 4801, 29, 21, 9457, 8091, 6573, 9, 3, 0, 0, 0, 0,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
Program only crashes as release build -- how to debug? === I've got a "Schroedinger's Cat" type of problem here -- my program (actually the test suite for my program, but a program nonetheless) is crashing, but only when built in release mode, and only when launched from the command line. Through caveman debugging (ie, nasty printf() messages all over the place), I have determined the test method where the code is crashing, though unfortunately the actual crash seems to happen in some destructor, since the last trace messages I see are in other destructors which execute cleanly. When I attempt to run this program inside of Visual Studio, it doesn't crash. Same goes when launching from WinDbg.exe. The crash only occurs when launching from the command line. This is happening under Windows Vista, btw, and unfortunately I don't have access to an XP machine right now to test on. It would be really nice if I could get Windows to print out a stack trace, or *something* other than simply terminating the program as if it had exited cleanly. Does anyone have any advice as to how I could get some more meaningful information here and hopefully fix this bug?
0
[ 2, 625, 104, 21563, 28, 830, 1895, 13, 8, 8, 184, 20, 121, 16254, 60, 800, 3726, 3726, 31, 22, 195, 330, 21, 13, 7, 18, 19642, 69, 11682, 22, 18, 2008, 7, 1001, 16, 1448, 235, 13, 8, 8, 51, 625, 13, 5, 15661, 14, 1289, 616...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What does it mean that Javascript is a prototype based langugage? === One of the major advantages with Javascript is said to be that it is a prototype based language. But what does it mean that Javascript is prototype based and why is that an advantage?
0
[ 2, 98, 630, 32, 884, 30, 8247, 8741, 25, 21, 7063, 432, 4544, 7149, 834, 60, 800, 3726, 3726, 53, 16, 14, 394, 14683, 29, 8247, 8741, 25, 87, 20, 44, 30, 32, 25, 21, 7063, 432, 816, 9, 47, 98, 630, 32, 884, 30, 8247, 8741, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0...
How best to get support and feedback for a new open source project? === I wish to start a new open source project. What internet resources are there for gathering support and feedback on the project?
0
[ 2, 184, 246, 20, 164, 555, 17, 13111, 26, 21, 78, 368, 1267, 669, 60, 800, 3726, 3726, 31, 2536, 20, 799, 21, 78, 368, 1267, 669, 9, 98, 2620, 2566, 50, 80, 26, 5822, 555, 17, 13111, 27, 14, 669, 60, 3, 0, 0, 0, 0, 0, 0,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
Is it time to start using HTML5? === Is it time to start using HTML5? Someone has to start sometime but is now the time? Is it possible to to use the new HTML5 tags and code in such a way as to degrade gracefully?
3
[ 2, 25, 32, 85, 20, 799, 568, 13, 15895, 264, 60, 800, 3726, 3726, 25, 32, 85, 20, 799, 568, 13, 15895, 264, 60, 737, 63, 20, 799, 8530, 47, 25, 130, 14, 85, 60, 25, 32, 938, 20, 20, 275, 14, 78, 13, 15895, 264, 3383, 18, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0...
How do you organize your release tests? === In the company where I work we have major releases twice every year. Extensive testing (automated and manual) is done the weeks before. The automated tests produce logfiles, the results of the manual tests are written down in test plans (Word documents). As you can imagine this results in a lot of different files to be managed and interpreted by the test engineers. <br> How do you `organize` your release tests? <br> E.g. Do use a bug tracker? Do you use any other tools? How do you specify what has to be tested? Who does the testing? How is the ratio developers / testers?
0
[ 2, 184, 107, 42, 9213, 154, 830, 4894, 60, 800, 3726, 3726, 19, 14, 237, 113, 31, 170, 95, 57, 394, 7073, 2088, 352, 159, 9, 3386, 4431, 13, 5, 18042, 79, 1669, 17, 5132, 6, 25, 677, 14, 1342, 115, 9, 14, 14904, 4894, 2213, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
.NET partial class' accessibility over multiple files === If I have the core of a class defined in one file as "public partial" and I wish to create additions to this in another file, what is the difference between defining "public partial" again in my second file or just defining "partial"? What happens if I define "private partial" in my second file?
0
[ 2, 13, 9, 2328, 7284, 718, 22, 25737, 84, 1886, 6488, 800, 3726, 3726, 100, 31, 57, 14, 2884, 16, 21, 718, 2811, 19, 53, 3893, 28, 13, 7, 12259, 7284, 7, 17, 31, 2536, 20, 1600, 848, 18, 20, 48, 19, 226, 3893, 15, 98, 25, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Convert XML Data to Strong Flex Type === A project I'm working on will pull XML from a web-server and build a data store from it. The data will have certain core fields but needs to be extendable... for example I have a <Person> and later might want to have <Policeman> which adds extra fields. In the Flex app, I don't want the central data store to be working on XML objects or simply putting the properties into Objects. I want to have strong types, e.g a Person class, which are created/populated from the XML. How can this be done in a flexible way? Is Flex able to automatically build a Person from an XML <Person> if the attribute names match, or do I need to write conversion functionality for <Person>, <Policeman>, etc?
0
[ 2, 8406, 23504, 1054, 20, 966, 14409, 1001, 800, 3726, 3726, 21, 669, 31, 22, 79, 638, 27, 129, 2201, 23504, 37, 21, 2741, 8, 10321, 106, 17, 1895, 21, 1054, 1718, 37, 32, 9, 14, 1054, 129, 57, 1200, 2884, 2861, 47, 2274, 20, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Best way to find nearest date nearest to target in a list of dates? === I have a list of Date objects, and a target Date. I want to find the date in the list that's nearest to the target date, but only dates that are before the target date. Example: 2008-10-1 2008-10-2 2008-10-4 With a target date of 2008-10-3, I want to get 2008-10-2 What is the best way to do it?
0
[ 2, 246, 161, 20, 477, 6557, 1231, 6557, 20, 2935, 19, 21, 968, 16, 4076, 60, 800, 3726, 3726, 31, 57, 21, 968, 16, 1231, 3916, 15, 17, 21, 2935, 1231, 9, 31, 259, 20, 477, 14, 1231, 19, 14, 968, 30, 22, 18, 6557, 20, 14, 2...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to create nestable draggables in Scriptaculous? === I'm using the Scriptaculous library to slap an appealing UI on an application which helps an enduser build lists. Let's say its for pizza creation. To fill out an order, you drag a size of pizza from the pizza palette into the orders droppable. Once it is put in there, it gets replaced with a new div which is both draggable (because you can junk it by moving it back to the palette) and droppable (because you can add ingredients to it). You can then add ingredients from your ingredients palette to any of the pizzas you have sitting in the group of orders. I've successfully implemented these bits and everything works fine. The stickler: if I attempt to drag and drop the ingredient from a placed pizza, which is properly marked as draggable and which, for good measure, is z-positioned above the pizza, it instead grabs the pizza wholesale. This makes it impossible for me to undo ingredient selections, which is a key feature for this screen. Any suggestions on how I can get this to do what I want? Ideally I'd like to keep the simple drag-on, drag-off UI as it is *worlds* more intuitive than what we were using previously. (A multi-stage HTML form... shudder...)
0
[ 2, 184, 20, 1600, 5618, 579, 5501, 263, 579, 18, 19, 3884, 1738, 22717, 60, 800, 3726, 3726, 31, 22, 79, 568, 14, 3884, 1738, 22717, 1248, 20, 11985, 40, 18518, 13, 5661, 27, 40, 3010, 56, 7778, 40, 241, 16704, 1895, 7227, 9, 40...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Where in JavaScript is the request coming from? === I am debugging a large, complex web page that has a lot of JavaScript, JQuery, Ajax and so on. Somewhere in that code I am getting a rouge request (I think it is an empty img) that calls the root of the server. I know it is not in the html or the css and am pretty convinced that somewhere in the JavaScript code the reqest is being made, but I can't track it down. I am used to using firebug, VS and other debugging tools but am looking for some way to find out where this is executed - so that I can find the offending line amongst about 150 .js files. Apart from putting in a gazzillion console outputs of 'you are now here', does anyone have suggestions for a debugging tool that could highlight where in Javascript requests to external resources are made? Any other ideas?
0
[ 2, 113, 19, 8247, 8741, 25, 14, 3772, 880, 37, 60, 800, 3726, 3726, 31, 589, 121, 16254, 2762, 21, 370, 15, 1502, 2741, 2478, 30, 63, 21, 865, 16, 8247, 8741, 15, 487, 8190, 93, 15, 20624, 17, 86, 27, 9, 3493, 19, 30, 1797, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Python - How to use Conch to creat a Virtual SSH server. === I'm looking at creating a server in python that I can run, and will work as an SSH server. This will then let different users login, and act as if they'd logged in normally, but only had access to one command. I want to do this so that I can have a system where I can add users to without having to create a system wide account, so that they can then, for example, commit to a VCS branch, or similar. While I can work out how to do this with conch to get it to a "custom" shell... I can't figure out how to make it so that the SSH stream works as if it were a real one (I'm preferably wanting to limit to /bin/bzr so that bzr+ssh will work.
0
[ 2, 20059, 13, 8, 184, 20, 275, 1065, 673, 20, 5059, 721, 21, 6599, 13, 18, 1635, 8128, 9, 800, 3726, 3726, 31, 22, 79, 699, 35, 2936, 21, 8128, 19, 20059, 30, 31, 92, 485, 15, 17, 129, 170, 28, 40, 13, 18, 1635, 8128, 9, 4...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
.NET Fastest way to iterate through rows in a datatable? === Which is generally fastest when reading/comparing row info from a DataTable? 'assume dt as datatable' 'method 1' dim i as int32 for i = 0 to dt.rows.count - 1 .... next 'method 2' dim row as datarow for each row in dt.rows .... next And if there's a difference, in what circumstances does it pay to use one over the other? Thanks in advance for any guidance!
0
[ 2, 13, 9, 2328, 7518, 161, 20, 32, 106, 1373, 120, 11295, 19, 21, 1054, 5924, 60, 800, 3726, 3726, 56, 25, 1469, 7518, 76, 1876, 118, 18415, 2090, 3131, 15404, 37, 21, 1054, 5924, 60, 13, 22, 9755, 9472, 13, 43, 38, 28, 1054, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Why is require_once so bad to use? === Everything I read about better php coding practices keeps saying don't use require_once because of speed. Why is this? What is the proper/better way to do the same thing as require_once (if it matters, i'm using php5)
0
[ 2, 483, 25, 4077, 1, 13120, 86, 896, 20, 275, 60, 800, 3726, 3726, 796, 31, 1302, 88, 574, 13, 26120, 13, 15458, 5242, 8968, 1148, 221, 22, 38, 275, 4077, 1, 13120, 185, 16, 1362, 9, 483, 25, 48, 60, 98, 25, 14, 4119, 118, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
onClose Event in ASP.net === Is there an event like onLoad....just at closing the Site (onClose)?
0
[ 2, 27, 14330, 807, 19, 28, 306, 9, 2328, 800, 3726, 3726, 25, 80, 40, 807, 101, 27, 8294, 9, 9, 9, 9, 2759, 35, 4239, 14, 689, 13, 5, 218, 14330, 6, 60, 3, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
SCJP exam - your best tips for passing === Having recently started studying for the SCJP exam, I was wondering where to put some extra focus. So, to those of you who have taken the test (and preferably passed): - Any particular topics I need to focus on? - Any pitfalls I should be particularly wary of? - Which part did you find hardest? Thanks!
0
[ 2, 4729, 12851, 11796, 13, 8, 154, 246, 11034, 26, 2848, 800, 3726, 3726, 452, 1989, 373, 4493, 26, 14, 4729, 12851, 11796, 15, 31, 23, 5712, 113, 20, 442, 109, 2230, 1776, 9, 86, 15, 20, 273, 16, 42, 72, 57, 658, 14, 1289, 13...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How can I auto filter a HTML selectlist? === I have a HTML select list with quite a few (1000+) names. I have a javascript in place which will select the first matching name if someone starts typing. This matching looks at the start of the item: var optionsLength = dropdownlist.options.length; for (var n=0; n < optionsLength; n++) { var optionText = dropdownlist.options[n].text; if (optionText.indexOf(dropdownlist.keypressBuffer,0) == 0) { dropdownlist.selectedIndex = n; return false; } } The customer would like to have a suggest or autofilter: typing part of a name should 'find' all names containing that part. I've seen a few Google Suggest like options, most using Ajax, but I'd like a pure javascript option, since the select list is already loaded anyway. Pointers anyone? -Edo
0
[ 2, 184, 92, 31, 3108, 11945, 21, 13, 15895, 5407, 5739, 60, 800, 3726, 3726, 31, 57, 21, 13, 15895, 5407, 968, 29, 1450, 21, 310, 13, 5, 19484, 2430, 6, 1817, 9, 31, 57, 21, 8247, 8741, 19, 209, 56, 129, 5407, 14, 64, 10120, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
how to reimplement jquery's default helper in a custom helper === I'm creating a custom drag helper (in jquery): $('.dragme', element).draggable({ appendTo: 'body', helper : custom_drag_helper, opacity : 0.5 }); I'm doing this because I want to sometimes clone and sometimes do the default functionality, i.e. drag the original element. function custom_drag_helper() { if (/*criteria on when to move instead of clone */) { return $(this); /* this is what helper: 'original' seems to does */ } else { clone = $(this).clone(); /* this is what helper: 'clone' does */ return clone; } } But I can't get the original functionality to work at all. return clone() works fine but return $(this) gives no joy.
0
[ 2, 184, 20, 302, 8983, 413, 1130, 487, 8190, 93, 22, 18, 12838, 448, 106, 19, 21, 5816, 448, 106, 800, 3726, 3726, 31, 22, 79, 2936, 21, 5816, 5501, 448, 106, 13, 5, 108, 487, 8190, 93, 6, 45, 5579, 5, 22, 9, 43, 11208, 790,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
DB: To use indetity column or not? === While designing a table my colleague here says that I should avoid identity column as it is specific to SQL Server and MS Access, But I differ with his views as it makes my coding simpler. Should I use identity column or not? If not what is best way to create the identity columns from application code?
0
[ 2, 13, 9007, 45, 20, 275, 19, 546, 38, 856, 4698, 54, 52, 60, 800, 3726, 3726, 133, 15026, 21, 859, 51, 12321, 235, 898, 30, 31, 378, 2658, 3270, 4698, 28, 32, 25, 1903, 20, 4444, 255, 8128, 17, 4235, 1381, 15, 47, 31, 11394, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Best Timer approach in C# console batch application === Which is the best timer approach for a C# console batch application that has to process as follows: 1. Connect to datasources 2. process batch until timeout occurs. "Do something with datasources" 3. stop console app gracefully. related question: http://stackoverflow.com/questions/186084/how-do-you-add-a-timer-to-a-c-console-application
0
[ 2, 246, 85, 139, 2141, 19, 272, 5910, 8650, 13064, 3010, 800, 3726, 3726, 56, 25, 14, 246, 85, 139, 2141, 26, 21, 272, 5910, 8650, 13064, 3010, 30, 63, 20, 953, 28, 2415, 45, 137, 9, 6379, 20, 1054, 12097, 18, 172, 9, 953, 130...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Deploying web apps that use cron === What is the best procedure for deploying web apps that rely on cron jobs (for cache maintenance, db updates, ...)? For things like DB schema changes, there are tools such as DBDeploy for managing the changes between versions, but how do you automate updates to the crontab? I know that the actual cron files are stored in /var/spool/ but I've heard that it is severely unwise to edit these directly. How do other people do it?
0
[ 2, 17617, 68, 2741, 4865, 18, 30, 275, 13, 19587, 800, 3726, 3726, 98, 25, 14, 246, 7004, 26, 17617, 68, 2741, 4865, 18, 30, 12139, 27, 13, 19587, 4844, 13, 5, 1106, 16522, 5010, 15, 13, 9007, 16779, 15, 13, 9, 9, 9, 6, 60, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do you document your database structure? === Most database systems I know of don't allow comments or descriptions of tables and fields, so how do you go about documenting the purpose of a table/field apart from the obvious of having good naming conventions? (Let's assume for now that "excellent" table and field names are not enough to document the full meaning of every table, field and relationship in the database.) I know many people use UML diagrams to visualize the database, but I have rarely&mdash;if ever&mdash;seen a UML diagram including field comments. However, I have good experience with using comments inside <code>.sql</code> files. The downside to this approach is that it requires the <code>.sql</code> files to be manually kept up-to-date as the database structure changes over time&mdash;but if you do, you can also have it under version control. Some other techniques I have seen are separate document describing database structure and relationships and manually maintained comments inside ORM code or other database-mapping code. How have you solved this problem in the past? What methods exists and what are the various pros and cons associated with them? How you would you like this solved in "a perfect world"?
0
[ 2, 184, 107, 42, 4492, 154, 6018, 1411, 60, 800, 3726, 3726, 127, 6018, 1242, 31, 143, 16, 221, 22, 38, 1655, 7534, 54, 15740, 16, 7484, 17, 2861, 15, 86, 184, 107, 42, 162, 88, 4492, 68, 14, 2131, 16, 21, 859, 118, 1109, 2629...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What is the most addictive feature you've encountered? === Hi I'm Gene and I'm an addict. I often find my self addicted to a website and I'm quite sure I'm not alone. So my question is what is the most addictive Web-site/appplication/feature you've encountered. And before someone closes this question as irrelevant I'd like to point out that the result will help all of us to build websites that gets the users to coming back for more. My own answer for the website would be the Game [Travian][1]. I've been playing for almost 2 years no. As features go the stackoverflows reputation system, is quite addictive. [1]: http://www.travian.com
0
[ 2, 98, 25, 14, 127, 29994, 1580, 42, 22, 195, 8208, 60, 800, 3726, 3726, 4148, 31, 22, 79, 3194, 17, 31, 22, 79, 40, 16906, 9, 31, 478, 477, 51, 1119, 16906, 69, 20, 21, 2271, 17, 31, 22, 79, 1450, 562, 31, 22, 79, 52, 105...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How to display a VRML model with .NET? === I have a request to display VRML models within a .NET application. Does someone know an easy way, maybe with standard .NET components, to achieve this? What are the issues I maybe have to face when representing VRML within an application? Thank you very much! Michael
0
[ 2, 184, 20, 3042, 21, 13, 6938, 8184, 1061, 29, 13, 9, 2328, 60, 800, 3726, 3726, 31, 57, 21, 3772, 20, 3042, 13, 6938, 8184, 2761, 363, 21, 13, 9, 2328, 3010, 9, 630, 737, 143, 40, 2010, 161, 15, 913, 29, 1236, 13, 9, 2328,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What is the size limit for a varchar2 procedure argument in Oracle 10g ? === When you create a procedure in Oracle PL/SQL, you cannot specify the maximum length of the varchar2 arguments, only the datatype. For example create or replace procedure testproc( arg1 varchar2 ) is begin ... ... end; Do you know the maximum length of a string that you can pass as the arg1 argument to this procedure in Oracle 10g ? Thanks!
0
[ 2, 98, 25, 14, 1072, 4496, 26, 21, 4033, 5433, 135, 7004, 5476, 19, 15759, 332, 263, 13, 60, 800, 3726, 3726, 76, 42, 1600, 21, 7004, 19, 15759, 12443, 118, 18, 22402, 15, 42, 1967, 19077, 14, 2979, 1476, 16, 14, 4033, 5433, 135...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Visual C++ unresolved external symbol (can't find one of my own functions) === This is a very basic problem that's frustrating me at the moment. Let's say within a single solution, I have two projects. Let's call the first project SimpleMath. It has one header file "Add.h" which has int add(int i, int j) and the implementation "Add.cpp" which has int add(int i, int j) { return i+j; } Now let's say in a second project I want to use the add function. However, this code: #include "..\SimpleMath\Add.h" int main() { add(1, 2); } results in "unresolved external symbol". How do I get the second program to "know" about the actual implementation in the .cpp file. As a side note all code is fictional this is not how I actually program.
0
[ 2, 3458, 272, 20512, 367, 99, 5594, 4763, 4886, 4678, 13, 5, 1245, 22, 38, 477, 53, 16, 51, 258, 3719, 6, 800, 3726, 3726, 48, 25, 21, 253, 2125, 1448, 30, 22, 18, 25568, 55, 35, 14, 688, 9, 408, 22, 18, 395, 363, 21, 345, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Mongrel cluster and multi-applications problem === we're running in this issue. We're using a web service (using soap4r) to run some kind of searches and the problem appears when the webservice server is down and our aplication is trying to connect to it. At that point the application is unreachable, and all the customers are blocked. What can we do to avoid that? Is possibile to block the routing to a mongrel that it is blocked? (I suppose that the apache's proxy uses a round-robin algohritm) Thanks Roberto
0
[ 2, 21028, 7256, 7460, 17, 1889, 8, 2552, 20669, 18, 1448, 800, 3726, 3726, 95, 22, 99, 946, 19, 48, 1513, 9, 95, 22, 99, 568, 21, 2741, 365, 13, 5, 12655, 6447, 300, 139, 6, 20, 485, 109, 825, 16, 19994, 17, 14, 1448, 1780, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Calculating days of week given a week number === Given a week number, e.g. `date -u +%W`, how do you calculate the days in that week starting from Monday? Example rfc-3339 output for week 40: 2008-10-06 2008-10-07 2008-10-08 2008-10-09 2008-10-10 2008-10-11 2008-10-12 Preferably want an implementation in Javascript, shell or PHP. :-)
0
[ 2, 22937, 509, 16, 877, 504, 21, 877, 234, 800, 3726, 3726, 504, 21, 877, 234, 15, 13, 62, 9, 263, 9, 13, 1, 8209, 13, 8, 291, 2754, 11881, 499, 1, 15, 184, 107, 42, 18469, 14, 509, 19, 30, 877, 1422, 37, 5745, 60, 823, 17...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What options are available for connecting to a Microsoft SQL Server database from an Oracle database? === At the moment I pull data from remote MS SQL Server databases using custom-built JDBC connectors. This works fine but doesn't feel like the way to do it. I feel I should be able to put a JDBC connection string into tnsnames on the server and have it "just work". I've looked around a little for this functionality but it doesn't seem to be there. In this way I could connect to pretty much any database just using a database link. Have I missed something?
0
[ 2, 98, 6368, 50, 904, 26, 6440, 20, 21, 7099, 4444, 255, 8128, 6018, 37, 40, 15759, 6018, 60, 800, 3726, 3726, 35, 14, 688, 31, 2201, 1054, 37, 5388, 4235, 4444, 255, 8128, 6018, 18, 568, 5816, 8, 8607, 487, 43, 7229, 17991, 18,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
What is the best practice to use ExtJS with Asp.net? === How do you save data from ExtJS form? Load data from the business layer into form or grid?
0
[ 2, 98, 25, 14, 246, 1345, 20, 275, 1396, 38, 728, 18, 29, 28, 306, 9, 2328, 60, 800, 3726, 3726, 184, 107, 42, 2079, 1054, 37, 1396, 38, 728, 18, 505, 60, 6305, 1054, 37, 14, 508, 5385, 77, 505, 54, 7354, 60, 3, 0, 0, 0, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
from X import a versus import X; X.a === This is one of those semi-religious Python questions that I suspect has well reasoned responses lurking in the community. I've seen some Python programmers use the following style fairly consistently (we'll call it style 1): import some_module # Use some_module.some_identifier in various places. For support of this style you can cite the ["explicit is better than implicit"][1] maxim. I've seen other programmers use this style (style 2): from some_module import some_identifier # Use some_identifier in various places. The primary benefit that I see in style 2 is maintainability -- especially with duck typing ideals I may want to swap some_module for some_other_module. I also feel style 2 wins points with the ["readability counts"][1] maxim. Although I tend to disagree, one can always argue that search-and-replace is just as good an option when using the first style. [1]: http://www.python.org/dev/peps/pep-0020/
0
[ 2, 37, 993, 9010, 21, 5706, 9010, 993, 73, 993, 9, 58, 800, 3726, 3726, 48, 25, 53, 16, 273, 1922, 8, 20075, 20059, 2346, 30, 31, 7551, 63, 134, 1215, 69, 13231, 26626, 19, 14, 514, 9, 31, 22, 195, 541, 109, 20059, 17968, 18, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Remove binding in WPF using code. === I would like to use databinding when displaying data in a TextBox. I'm basically doing like: public void ShowRandomObject(IRandomObject randomObject) { Binding binding = new Binding {Source = randomObject, Path = new PropertyPath("Name")}; txtName.SetBinding(TextBox.TextProperty, binding); } I can't seem to find a way to unset the binding. I will be calling this method with a lot of different objects but the TextBox will remain the same. Is there a way to remove the previous binding or is this done automatically when I set the new binding?
0
[ 2, 4681, 8728, 19, 619, 7721, 568, 1797, 9, 800, 3726, 3726, 31, 83, 101, 20, 275, 1054, 22260, 76, 17418, 1054, 19, 21, 1854, 5309, 9, 31, 22, 79, 11374, 845, 101, 45, 317, 11364, 298, 2195, 5555, 23793, 5, 20044, 5555, 23793, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
In managed C++, how do I declare and call a function with an 'out' parameter? === I have a function which parses one string into two strings. In C# I would declare it like this: void ParseQuery(string toParse, out string search, out string sort) { ... } and I'd call it like this: string searchOutput, sortOutput; ParseQuery(userInput, out searchOutput, out sortOutput); The current project has to be done in managed C++. I've tried using System::Runtime::InteropServices; ... void ParseQuery(String ^ toParse, [Out] String^ search, [Out] String^ sort) { ... } but if I call it like this: String ^ searchOutput, ^ sortOutput; ParseQuery(userInput, [Out] searchOutput, [Out] sortOutput); I get a compiler error, and if I call it like this: String ^ searchOutput, ^ sortOutput; ParseQuery(userInput, searchOutput, sortOutput); then I get an error at runtime. How should I declare and call my function?
0
[ 2, 19, 1471, 272, 20512, 15, 184, 107, 31, 10123, 17, 645, 21, 1990, 29, 40, 13, 22, 1320, 22, 18906, 60, 800, 3726, 3726, 31, 57, 21, 1990, 56, 2017, 7202, 53, 3724, 77, 81, 7887, 9, 19, 272, 5910, 31, 83, 10123, 32, 101, 4...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
How do I code a Mono Daemon === I'm trying to write a Mono C# daemon for linux. I'd like to do a starts and stops of it when its done processing instead of just killing the process. Does anyone have any examples of this?
0
[ 2, 184, 107, 31, 1797, 21, 4129, 13127, 800, 3726, 3726, 31, 22, 79, 749, 20, 2757, 21, 4129, 272, 5910, 13127, 26, 13024, 9, 31, 22, 43, 101, 20, 107, 21, 3244, 17, 6604, 16, 32, 76, 82, 677, 5511, 700, 16, 114, 2389, 14, 9...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0...
if(str1==str2) versus if(str1.length()==str2.length() && str1==str2) === I've seen second one in another's code and I suppose this length comparison have been done to increase code productivity. It was used in a parser for a script language with a specific dictionary: words are 4 to 24 letters long with the average of 7-8 lettets, alphabet includes 26 latin letters plus "@","$" and "_". Length comparison were used to escape == operator working with STL strings, which obviously takes more time then simple integer comparison. But in the same time first letter distribution in the given dictionary is simply wider than a distribution of words size, so two first letters of comparing strings will be generally more often different, than the sizes of that strings. That makes length comparison unnecessary. I've ran some tests and that is what I've found out: While testing two random strings comparison million times, second way is much faster, so length comparison seems to be helpful. But in a working project it works even slower in a debug mode and insufficiantly faster in a release mode. So, my question is: why length comparison can fasten the comparison and why can it slow it down?
0
[ 2, 100, 5, 9729, 165, 3726, 3726, 9729, 135, 6, 5706, 100, 5, 9729, 165, 9, 6325, 5, 6, 3726, 3726, 9729, 135, 9, 6325, 5, 6, 279, 1569, 13, 9729, 165, 3726, 3726, 9729, 135, 6, 800, 3726, 3726, 31, 22, 195, 541, 153, 53, 19...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
list resources in package === lets assume my classes are loaded from a compressed .war file or loaded elsewhere, how can i discover all the resources in a given package? enumerating files will not really work, since this is a war file. most likely this will involve using the current classloader? is there a library out there that does something like that? googling revealed only some hacks with listing files.
0
[ 2, 968, 2566, 19, 6030, 800, 3726, 3726, 6884, 7158, 51, 2684, 50, 8572, 37, 21, 18472, 13, 9, 1885, 3893, 54, 8572, 6040, 15, 184, 92, 31, 6297, 65, 14, 2566, 19, 21, 504, 6030, 60, 26940, 68, 6488, 129, 52, 510, 170, 15, 179...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
DllMain in an exe? === Is it possible to receive DllMain like notifications about thread attach/detach in stand-alone exe without using any extra dlls?
0
[ 2, 13, 43, 211, 6232, 19, 40, 1396, 62, 60, 800, 3726, 3726, 25, 32, 938, 20, 2588, 13, 43, 211, 6232, 101, 52, 4634, 18, 88, 9322, 19514, 118, 546, 38, 3211, 19, 1261, 8, 17979, 1396, 62, 366, 568, 186, 2230, 13, 43, 211, 1...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
Flexible Decorator Pattern? === I was looking for a pattern to model something I'm thinking of doing in a personal project and I was wondering if a modified version of the decorator patter would work. Basicly I'm thinking of creating a game where the characters attributes are modified by what items they have equiped. The way that the decorator stacks it's modifications is perfect for this, however I've never seen a decorator that allows you to drop intermediate decorators, which is what would happen when items are unequiped. Does anyone have experience using the decorator pattern in this way? Or am I barking up the wrong tree?
0
[ 2, 13568, 17650, 3457, 3732, 60, 800, 3726, 3726, 31, 23, 699, 26, 21, 3732, 20, 1061, 301, 31, 22, 79, 1440, 16, 845, 19, 21, 1319, 669, 17, 31, 23, 5712, 100, 21, 5372, 615, 16, 14, 17650, 3457, 2678, 815, 83, 170, 9, 2125, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
PHP's file_get_contents not returning until remote servers' keep-alive limit is exceeded === From one apache server file_get_contents returns the contents of a url straight away. On another apache server file_get contents won't return the contents of the same url until the keep-alive limit of the server hosting that url has been expired. The 2 php servers are retrieving the same url but through different network routes. What could be causing one php installation to wait for the remote keep-alive limit before returning?
0
[ 2, 13, 26120, 22, 18, 3893, 1, 3060, 1, 25424, 18, 52, 2485, 163, 5388, 17595, 22, 643, 8, 192, 1284, 4496, 25, 17365, 800, 3726, 3726, 37, 53, 17140, 8128, 3893, 1, 3060, 1, 25424, 18, 4815, 14, 8478, 16, 21, 287, 6362, 1599, ...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...
Better way to profile? === Is there a better way to profile code then: $start1 = microtime(TRUE); for($i=0;$i<count($array);$i++) { //do something } $time1 = microtime(TRUE) - $start1;
0
[ 2, 574, 161, 20, 5296, 60, 800, 3726, 3726, 25, 80, 21, 574, 161, 20, 5296, 1797, 94, 45, 5579, 13680, 165, 800, 2899, 891, 5, 13398, 6, 73, 26, 5, 4403, 49, 3726, 387, 73, 4403, 49, 1, 16549, 5, 4403, 8576, 93, 6, 73, 4403,...
[ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0...
[ 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1...