Search Results

Search found 11197 results on 448 pages for 'related'.

Page 146/448 | < Previous Page | 142 143 144 145 146 147 148 149 150 151 152 153  | Next Page >

  • c++ dynamic_cast error handling

    - by Nazgob
    Is there any good practice related to dynamic_cast error handling (except not using it when you don't have to)? I'm wondering how should I go about NULL and bad_cast it can throw. Should I check for both? And if I catch bad_cast or detect NULL I probably can't recover anyway... For now, I'm using assert to check if dynamic_cast returned not NULL value. Would you accept this solution on a code review?

    Read the article

  • What are some good programming challenge websites?

    - by Martin
    I used to be a member of +Ma's Reversing, and later became a member of Caesum's Electrica. Recently I've played Bright Shadows. Are there other good sites for a challenge? Question reopened; not a duplicate. Similar, yes, but slightly different. Related: http://stackoverflow.com/questions/24692/where-can-you-find-funeducational-programming-challenges

    Read the article

  • How to manage multiple versions of the same record

    - by Darvis Lombardo
    I am doing short-term contract work for a company that is trying to implement a check-in/check-out type of workflow for their database records. Here's how it should work... 1) A user creates a new entity within the application. There are about 20 related tables that will be populated in addition to the main entity table. 2) Once the entity is created the user will mark it as the master. 3) Another user can make changes to the master only by "checking out" the entity. Multiple users can checkout the entity at the same time. 4) Once the user has made all the necessary changes to the entity, they put it in a "needs approval" status. 5) After an authorized user reviews the entity, they can promote it to master which will put the original record in a tombstoned status. The way they are currently accomplishing the "check out" is by duplicating the entity records in all the tables. The primary keys include EntityID + EntityDate, so they duplicate the entity records in all related tables with the same EntityID and an updated EntityDate and give it a status of "checked out". When the record is put into the next state (needs approval), the duplication occurs again. Eventually it will be promoted to master at which time the final record is marked as master and the original master is marked as dead. This design seems hideous to me, but I understand why they've done it. When someone looks up an entity from within the application, they need to see all current versions of that entity. This was a very straightforward way for making that happen. But the fact that they are representing the same entity multiple times within the same table(s) doesn't sit well with me, nor does the fact that they are duplicating EVERY piece of data rather than only storing deltas. I would be interested in hearing your reaction to the design, whether positive or negative. I would also be grateful for any resoures you can point me to that might be useful for seeing how someone else has implemented such a mechanism. Thanks! Darvis

    Read the article

  • Is Horde an acceptable framework for PHP groupware development?

    - by Glenn
    I'm working on this project and the customer wants it to integrate with a groupware package including bulk email, calendars, and task lists. He has heard about Horde and Horde GroupWare and is interested in using that. Do you have any developer related experience with Horde? If so, then what were your findings? Did you find it to be stable? What about the framework/API? Was it easy to integrate with?

    Read the article

  • anybody using AmaterasUML in eclipse

    - by krisp
    Does it automatically creates the sequeance diagram? or we have to drag and drop the related java files and then manually create the sequence diagram? This was the only link i could find on google http://amateras.sourceforge.jp/cgi-bin/fswiki_en/wiki.cgi?page=AmaterasUML Thanks

    Read the article

  • How do I calculate the week number given a date?

    - by GH
    If I have a date, how do I calculate the week number for that date within that year? For example, in 2008, January 1st to January 6th are in week 1 and January 7th to the 13th are in week 2, so if my date was January 10th 2008, my week number would be 2. An algorithm would be great to get me started and sample code would also help - I'm developing in C++ on Windows. Related: Getting week number off a date in MS SQL Server 2005?

    Read the article

  • SQL join produces one result only

    - by Rami
    Can anyone please tell me why this result is generation only one results? taking in mind that everything is set right and the three tables are populated correctly, i took out the group_concat and it worked but of course with a php undefined index error! SELECT `songs`.`song_name`, `songs`.`add_date`, `songs`.`song_id`, `songs`.`song_picture`, group_concat(DISTINCT artists.artist_name) as artist_name FROM (`songs`) JOIN `mtm_songs_artists` ON `songs`.`song_id` = `mtm_songs_artists`.`song_id` JOIN `artists` ON `artists`.`artist_id` = `mtm_songs_artists`.`artist_id` ORDER BY `songs`.`song_id` DESC LIMIT 10 so i'm guessing it's something related to group_concat. best regards, Rami

    Read the article

  • parse [object XrayWrapper [object HTMLLIElement]] into HTML object

    - by kitokid
    when I access and GM_log the currentLi of li object, it is complaining undefined. So when I GM_log li value as a string , instead of HTML object, I am getting [object XrayWrapper [object HTMLLIElement]]. How can I convert it or how I can access its related elements and value ? $("#result-set li").each(function(index) { var $currentLi = $(this); var $class1link = $currentLi.find("class1"); var $class1href = $class1link.attr("href"); }

    Read the article

  • Semantic urls with dots in .net

    - by Jokin
    I'm trying to make semantic urls for search pages, but if someone use a search finished in dot, the .net engine return a 404. The request don't even get to the routing engine, so i think its something related to security or something like that. For example, the stackoverflow routes also don't work in these case: http://stackoverflow.com/questions/tagged/etc.

    Read the article

  • liferay portal with asp.net

    - by harrisonmeister
    Hi This is a java noob related question. Have been looking at Liferay portal technology, however I'm a dotnet (c# or vb) developer by day. Does anyone know if you can use the install of liferay to host dotnet code, not just by using the iFrame method of redirecting to a different site - that just sucks in my opinion Alternatively is the saner option to go down the port my skills back to java? Thanks Mark

    Read the article

  • Creating and editing CSS in Flex3 Air

    - by vineth
    Hi, I need to create a CSS file via the Flex 3 Air application. I need to create and edit the CSS file and access individual styles by class name. Please give any examples or related links of which you aware. Thanks & Regards Vinod.P

    Read the article

  • Recommend me a good JNI book

    - by Jose Figueroa
    Hello, I'm creating a software project in Java, is a remote administration tool. The thing is that I need to add some features with C++ and I read some about this process and I realized I need JNI, could you recommend me a good JNI Book or something related with ?

    Read the article

  • How to Use Accordian Control in GridView

    - by Khilen
    i have Category & subCategory Detail i want that in Header of Accordion i can get Category Detail and when click on that related subcategory is displayed but i am retrieving data from database and even the subcateogry will contain a gridview so please give me example how to make such

    Read the article

  • Drupal 6: Block visibility settings...

    - by artmania
    Hi friends, I'm new at Drupal. my url is like www.blabla.com/drupal/blog/ I have some blocks that must be disabled for blog part. So I go to related block configuration and make it as below: but it doesnt work :( just to test, I wrote only * , and it worked well. but i doesnt work when I want to define specific page :(

    Read the article

  • translating specifications into query predicates

    - by Jeroen
    I'm trying to find a nice and elegant way to query database content based on DDD "specifications". In domain driven design, a specification is used to check if some object, also known as the candidate, is compliant to a (domain specific) requirement. For example, the specification 'IsTaskDone' goes like: class IsTaskDone extends Specification<Task> { boolean isSatisfiedBy(Task candidate) { return candidate.isDone(); } } The above specification can be used for many purposes, e.g. it can be used to validate if a task has been completed, or to filter all completed tasks from a collection. However, I want to re-use this, nice, domain related specification to query on the database. Of course, the easiest solution would be to retrieve all entities of our desired type from the database, and filter that list in-memory by looping and removing non-matching entities. But clearly that would not be optimal for performance, especially when the entity count in our db increases. Proposal So my idea is to create a 'ConversionManager' that translates my specification into a persistence technique specific criteria, think of the JPA predicate class. The services looks as follows: public interface JpaSpecificationConversionManager { <T> Predicate getPredicateFor(Specification<T> specification, Root<T> root, CriteriaQuery<?> cq, CriteriaBuilder cb); JpaSpecificationConversionManager registerConverter(JpaSpecificationConverter<?, ?> converter); } By using our manager, the users can register their own conversion logic, isolating the domain related specification from persistence specific logic. To minimize the configuration of our manager, I want to use annotations on my converter classes, allowing the manager to automatically register those converters. JPA repository implementations could then use my manager, via dependency injection, to offer a find by specification method. Providing a find by specification should drastically reduce the number of methods on our repository interface. In theory, this all sounds decent, but I feel like I'm missing something critical. What do you guys think of my proposal, does it comply to the DDD way of thinking? Or is there already a framework that does something identical to what I just described?

    Read the article

  • What is window message for a loaded website in Internet Explorer?

    - by karikari
    I am currently have this message handler line: MESSAGE_HANDLER(`WM_SETREDRAW`, onSetRedraw) I would like to know, is there any window message (eg: WM_???) that is connected/related to 'when a website has finish loading inside IE' ? So I can use it to replace the above WM_SETREDRAW. I want to do something like, when the IE finish loaded a website, it call onSetRedraw.

    Read the article

  • How to filter adult words

    - by javanes
    Hi; I am developing a web application, and do not want people to publish adult (pornographic) content. So is there a service or a list of words which are porn related? Or is there another way to filter adult content? Thanks.. See also How do you implement a good profanity filter?

    Read the article

  • Search the Quartz maps

    - by user197127
    Hi, I would like to store some properties in the quartz datastore (jdbc) and then be able to find all triggers/jobs that match. E.g. store the user id related to a trigger and then query like user_id=555. Previously, I used to query the database directly but this is naturally not a good way. Anyone has another suggestion on how to accomplish this? Thanks.

    Read the article

  • 47 memory leaks. STL pointers.

    - by icelated
    I have a major amount of memory leaks. I know that the Sets have pointers and i cannot change that! I cannot change anything, but clean up the mess i have... I am creating memory with new in just about every function to add information to the sets. I have a Cd/ DVD/book: super classes of ITEM class and a library class.. In the library class i have 2 functions for cleaning up the sets.. Also, the CD, DVD, book destructors are not being called.. here is my potential leaks.. library.h #pragma once #include <ostream> #include <map> #include <set> #include <string> #include "Item.h" using namespace std; typedef set<Item*> ItemSet; typedef map<string,Item*> ItemMap; typedef map<string,ItemSet*> ItemSetMap; class Library { public: // general functions void addKeywordForItem(const Item* const item, const string& keyword); const ItemSet* itemsForKeyword(const string& keyword) const; void printItem(ostream& out, const Item* const item) const; // book-related functions const Item* addBook(const string& title, const string& author, int const nPages); const ItemSet* booksByAuthor(const string& author) const; const ItemSet* books() const; // music-related functions const Item* addMusicCD(const string& title, const string& band, const int nSongs); void addBandMember(const Item* const musicCD, const string& member); const ItemSet* musicByBand(const string& band) const; const ItemSet* musicByMusician(const string& musician) const; const ItemSet* musicCDs() const; // movie-related functions const Item* addMovieDVD(const string& title, const string& director, const int nScenes); void addCastMember(const Item* const movie, const string& member); const ItemSet* moviesByDirector(const string& director) const; const ItemSet* moviesByActor(const string& actor) const; const ItemSet* movies() const; ~Library(); void Purge(ItemSet &set); void Purge(ItemSetMap &map); }; here is some functions for adding info using new in library. Keep in mind i am cutting out alot of code to keep this post short. library.cpp #include "Library.h" #include "book.h" #include "cd.h" #include "dvd.h" #include <iostream> // general functions ItemSet allBooks; ItemSet allCDS; ItemSet allDVDs; ItemSetMap allBooksByAuthor; ItemSetMap allmoviesByDirector; ItemSetMap allmoviesByActor; ItemSetMap allMusicByBand; ItemSetMap allMusicByMusician; const ItemSet* Library::itemsForKeyword(const string& keyword) const { const StringSet* kw; ItemSet* obj = new ItemSet(); return obj; const Item* Library::addBook(const string& title, const string& author, const int nPages) { ItemSet* obj = new ItemSet(); Book* item = new Book(title,author,nPages); allBooks.insert(item); // add to set of all books obj->insert(item); return item; const Item* Library::addMusicCD(const string& title, const string& band, const int nSongs) { ItemSet* obj = new ItemSet(); CD* item = new CD(title,band,nSongs); return item; void Library::addBandMember(const Item* musicCD, const string& member) { ItemSet* obj = new ItemSet(); (((CD*) musicCD)->addBandMember(member)); obj->insert((CD*) musicCD); here is the library destructor..... Library::~Library() { Purge(allBooks); Purge(allCDS); Purge(allDVDs); Purge(allBooksByAuthor); Purge(allmoviesByDirector); Purge(allmoviesByActor); Purge(allMusicByBand); Purge(allMusicByMusician); } void Library::Purge(ItemSet &set) { for (ItemSet::iterator it = set.begin(); it != set.end(); ++it) delete *it; set.clear(); } void Library::Purge(ItemSetMap &map) { for (ItemSetMap::iterator it = map.begin(); it != map.end(); ++it) delete it->second; map.clear(); } so, basically item, cd, dvd class all have a set like this: typedef set<string> StringSet; class CD : public Item StringSet* music; and i am deleting it like: but those superclasses are not being called.. Item destructor is. CD::~CD() { delete music; } Do, i need a copy constructor? and how do i delete those objects i am creating in the library class? and how can i get the cd,dvd, destructor called? would the addbandmember function located in the library.cpp cause me to have a copy constructor? Any real help you can provide me to help me clean up this mess instead of telling me not to use pointers in my sets i would really appreciate. How can i delete the memory i am creating in those functions? I cannot delete them in the function!!

    Read the article

< Previous Page | 142 143 144 145 146 147 148 149 150 151 152 153  | Next Page >