Search Results

Search found 8397 results on 336 pages for 'implementation'.

Page 135/336 | < Previous Page | 131 132 133 134 135 136 137 138 139 140 141 142  | Next Page >

  • Nested function in C

    - by Sachin Chourasiya
    Can we have a nested function in C? What is the use of nested functions? If they exist in C does there implementation differes from compiler to compiler. Are nested functions allowed in any other language? If yes then what is there significance?

    Read the article

  • GAE update different fields of the same entity

    - by bach
    Hi, UserA and UserB are changing objectA.filedA objectA.filedB respectively and at the same time. Because they are not changing the same field one might think that there are no overlaps. Is that true? or the implementation of pm.makePersistnace() actually override the whole object... good to know...

    Read the article

  • Realtime MySQL search results on an advanced search page

    - by Andrew Heath
    I'm a hobbyist, and started learning PHP last September solely to build a hobby website that I had always wished and dreamed another more competent person might make. I enjoy programming, but I have little free time and enjoy a wide range of other interests and activities. I feel learning PHP alone can probably allow me to create 98% of the desired features for my site, but that last 2% is awfully appealing: The most powerful tool of the site is an advanced search page that picks through a 1000+ record game scenario database. Users can data-mine to tremendous depths - this advanced page has upwards of 50 different potential variables. It's designed to allow the hardcore user to search on almost any possible combination of data in our database and it works well. Those who aren't interested in wading through the sea of options may use the Basic Search, which is comprised of the most popular parts of the Advanced search. Because the advanced search is so comprehensive, and because the database is rather small (less than 1,200 potential hits maximum), with each variable you choose to include the likelihood of getting any qualifying results at all drops dramatically. In my fantasy land where I can wield AJAX as if it were Excalibur, my users would have a realtime Total Results counter in the corner of their screen as they used this page, which would automatically update its query structure and report how many results will be displayed with the addition of each variable. In this way it would be effortless to know just how many variables are enough, and when you've gone and added one that zeroes out the results set. A somewhat similar implementation, at least visually, would be the Subtotal sidebar when building a new custom computer on IBuyPower.com For those of you actually still reading this, my question is really rather simple: Given the time & ability constraints outlined above, would I be able to learn just enough AJAX (or whatever) needed to pull this one feature off without too much trouble? would I be able to more or less drop-in a pre-written code snippet and tweak to fit? or should I consider opening my code up to a trusted & capable individual in the future for this implementation? (assuming I can find one...) Thank you.

    Read the article

  • Implement eBay Finding/Feedback API [Java]

    - by zengr
    Hi, I have just started with the ebay Finding API and Feedback API and I need to deploy a basic API implementation on GAE/J. The problems are: How do we start with the local dev environment of the ebay SDK? There is no Java tutorial for the Finding API and feedback. GAE/J + ebay APIs won't cause any complexity right? I am looking for head start in the right direction,I am using Eclipse + GAE plugin.

    Read the article

  • Log4j Properties in a Custom Place

    - by Azder
    I'm using Apache Commons Logging and SLF4J with log4j, but I also want to use the log4j.properties in a custom place like conf/log4.properties. Here is the problem: If i use PropertyConfigurator.configure("conf/log4j.properties"); then my app is tied to log4j and defets the purpose of having ACL and SLF4J. What is the best way to configure it withouth the app ever knowing what the logging implementation is?

    Read the article

  • Safe Cross Thread Signals/Slot C++

    - by JP
    It seem that the only implementation that provide Safe Cross-Thread Signals for both the Signal class and what's being called in the slot is QT. (Maybe I'm wrong?). But I cannot use QT in the project I'm doing. So how could I provide safe Slots call from a different thread (Using Boost::signals2 for example)? Are mutex inside the slot the only way? I think signals2 protect themself but not what's being done inside the slot. Thanks

    Read the article

  • What does this `_time_independent_equals` mean?

    - by Satoru.Logic
    In the tornado.web module there is a function called _time_independent_equals: def _time_independent_equals(a, b): if len(a) != len(b): return False result = 0 for x, y in zip(a, b): result |= ord(x) ^ ord(y) return result == 0 It is used to compare secure cookie signatures, and thus the name. But regarding the implementation of this function, is it just a complex way to say a==b?

    Read the article

  • Well tested C/C++ lock free queue?

    - by uj
    I am looking for a well-tested, publicly available C/C++ implementation of a lock free queue. I need at least multiple-producers/single-consumer functionality. Multiple-consumers is even better, if exists. I'm targetting VC's _Interlocked... intrinsics, though anything which is straight forward to port would be fine. Could anyone give any pointers?

    Read the article

  • How to animate line-drawing in iPhone development?

    - by david
    I have been searching around, but there seems no good answer for this simple question. So I am asking again: how to animate line-drawing in iphone dev? Basically what I want is something like this: @implementation MyUIView - (void) triggerLineDrawing: (CGPathRef) path { ... // animate line drawing here } Can it be done?

    Read the article

  • Is there already FUSE filesystem that serialise each request to stream?

    - by Vi
    Concept: nc -lp 1234 -e fusexmp_server nc 127.0.0.1 1234 -c "fusestream /mnt/tmp" Advantages are: Easy implementation of servers in high level language (without need of any arch-dependent things like JNI or whatever) Simple ad-hoc networking filesystem out of the box. Accessibility without actual FUSE (when it is inaccessible): nc -lp 1234 -e fusexmp_server& fakefusestream 127.0.0.1 1234 % ls bin lib usr proc etc % get /etc/hosts % exit Is there already such thing or I should implement it?

    Read the article

  • How to infer the type of a derived class in base class?

    - by enzi
    I want to create a method that allows me to change arbitrary properties of classes that derive from my base class, the result should look like this: SetPropertyValue("size.height", 50); – where size is a property of my derived class and height is a property of size. I'm almost done with my implementation but there's one final obstacle that I want to solve before moving on, to describe this I will first have to explain my implementation a bit: Properties that can be modified are decorated with an attribute There's a method in my base class that searches for all derived classes and their decorated properties For each property I generate a "property modifier", a class that contains 2 delegates: one to set and one to get the value of the property. Property Modifiers are stored in a dictionary, with the name of the property as key In my base class, there is another dictionary that contains all property-modifier-dictionaries, with the Type of the respective class as key. What the SetPropertyValue method does is this: Get the correct property-modifier-dictionary, using the concrete type of the derived class (<- yet to solve) Get the property modifier of the property to change (e.g. of the property size) Use the get or set delegate to modify the property's value Some example code to clarify further: private static Dictionary<RuntimeTypeHandle, object> EditableTypes; //property-modifier-dictionary protected void SetPropertyValue<T>(EditablePropertyMap<T> map, string property, object value) { var property = map[property]; // get the property modifier property.Set((T)this, value); // use the set delegate (encapsulated in a method) } In the above code, T is the Type of the actual (derived) class. I need this type for the get/set delegates. The problem is how to get the EditablePropertyMap<T> when I don't know what T is. My current (ugly) solution is to pass the map in an overriden virtual method in the derived class: public override void SetPropertyValue(string property, object value) { base.SetPropertyValue((EditablePropertyMap<ExampleType>)EditableTypes[typeof(ExampleType)], property, value); } What this does is: get the correct dictionary containing the property modifiers of this class using the class's type, cast it to the appropiate type and pass it to the SetPropertyValue method. I want to get rid of the SetPropertyValue method in my derived class (since there are a lot of derived classes), but don't know yet how to accomplish that. I cannot just make a virtual GetEditablePropertyMap<T> method because I cannot infer a concrete type for T then. I also cannot acces my dictionary directly with a type and retrieve an EditablePropertyMap<T> from it because I cannot cast to it from object in the base class, since again I do not know T. I found some neat tricks to infere types (e.g. by adding a dummy T parameter), but cannot apply them to my specific problem. I'd highly appreciate any suggestions you may have for me.

    Read the article

  • Is a Multi-DAL Approach the way to go here?

    - by Krisc
    Working on the data access / model layer in this little MVC2 project and trying to think things out to future projects. I have a database with some basic tables and I have classes in the model layer that represent them. I obviously need something to connect the two. The easiest is to provide some sort of 'provider' that can run operations on the database and return objects. But this is for a website that would potentially be used "a lot" (I know, very general) so I want to cache results from the data layer and keep the cache updated as new data is generated. This question deals with how best to approach this problem of dual DALS. One that returns cached data when possible and goes to the data layer when there is a cache miss. But more importantly, how to integrate the core provider (thing that goes into database) with the caching layer so that it too can rely on cached objects rather than creating new ones. Right now I have the following interfaces: IDataProvider is used to reach the database. It doesn't concern itself with the meaning of the objects it produces, but simply the way to produce them. interface IDataProvider{ // Select, Update, Create, et cetera access IEnumerable<Entry> GetEntries(); Entry GetEntryById(int id); } IDataManager is a layer that sits on top of the IDataProvider layer and manages the cache interface IDataManager : IDataProvider{ void ClearCache(); } Note that in practice the IDataManager implementation will have useful helper functions to add objects to their related cache stores. (In the future I may define other functions on the interface) I guess what I am looking for is the best way to approach a loop back from the IDataProvider implementations so that they can access the cache. Or a different approach entirely may be in order? I am not very interested in 3rd party products at the moment as I am interested in the design of these things much more than this specific implementation. Edit: I realize the title may be a bit misleading. I apologize for that... not sure what to call this question.

    Read the article

  • Find most significant bit (left-most) that is set in a bit array

    - by Claudiu
    I have a bit array implementation where the 0th index is the MSB of the first byte in an array, the 8th index is the MSB of the second byte, etc... What's a fast way to find the first bit that is set in this bit array? All the related solutions I have looked up find the first least significant bit, but I need the first most significant one. So, given 0x00A1, I want 9.

    Read the article

  • How does Python store lists internally?

    - by Mike Cooper
    How are lists in python stored internally? Is it an array? A linked list? Something else? Or does the interpreter guess at the right structure for each instance based on length, etc. If the question is implementation dependent, what about the classic CPython?

    Read the article

  • What is the fastest XML parser in PHP?

    - by Jakub Lédl
    Hi, for a certain project, I need some way to parse XML and get data from it. So I wonder, which one of built-in parsers is the fastest? Also, it would be nice of the parser could accept a XML string as input - I have my own implementation of thread-safe working with files and I don't want some nasty non-thread-safe libraries to make my efforts useless.

    Read the article

  • How to read expected child nodes of a given node from schema in PHP?

    - by MartyIX
    I was wondering if there's an implementation of a XML schema reader that for an arbitrary node in XML schema provides list of nodes which are supposed to be present as child nodes of given node, restrictions on nodes and so on. I'm planning to program it for my purposes but I would like to know if it isn't solved somewhere. I really need only a small subset what I described above. Thanks for tips!

    Read the article

  • Displaying text in C# from XML via LINQ

    - by xscape
    Is there a way to display "Test" value as bold just like the implementation of newline? <testElement>Test &#xD; Test</testElement> The output of the above line when you display it is: TEST TEST I want to know what/how to make the second line as bold just line by using expressions. Thank you

    Read the article

  • what is the best method of concatenating a series of binary files into one file?

    - by Andrew
    hello everyone i have a series of PDF byte arrays in a arraylist files that i wish to concatenate into one file, currently when the PDF application trys to open the file is it corrupted: foreach (byte[] array in files) { using (Stream s = new MemoryStream(downloadbytes)) { s.Write(array, 0, array.Length); } } downloadbytes is the resultant concatenated array of bytes below is another implementation which also failed foreach (byte[] array in files) { System.Buffer.BlockCopy(array, 0, downloadbytes, offset, array.Length); offset += array.Length; } any pointers?

    Read the article

  • sql generate unique table/view name

    - by Claudiu
    I want to create some mad robust code. I want to take a query as a string, create a temporary view / table to store the results, use it, then drop the table. I want to use a name that is guaranteed to not already exist in the database. Is there an SQL command to generate a unique table name? I'm using postgresql if this is implementation-specific.

    Read the article

< Previous Page | 131 132 133 134 135 136 137 138 139 140 141 142  | Next Page >