Search Results

Search found 20383 results on 816 pages for 'hello'.

Page 285/816 | < Previous Page | 281 282 283 284 285 286 287 288 289 290 291 292  | Next Page >

  • Can't insert a number into a C++ custom streambuf/ostream

    - by 0xbe5077ed
    I have written a custom std::basic_streambuf and std::basic_ostream because I want an output stream that I can get a JNI string from in a manner similar to how you can call std::ostringstream::str(). These classes are quite simple. namespace myns { class jni_utf16_streambuf : public std::basic_streambuf<char16_t> { JNIEnv * d_env; std::vector<char16_t> d_buf; virtual int_type overflow(int_type); public: jni_utf16_streambuf(JNIEnv *); jstring jstr() const; }; typedef std::basic_ostream<char16_t, std::char_traits<char16_t>> utf16_ostream; class jni_utf16_ostream : public utf16_ostream { jni_utf16_streambuf d_buf; public: jni_utf16_ostream(JNIEnv *); jstring jstr() const; }; // ... } // namespace myns In addition, I have made four overloads of operator<<, all in the same namespace: namespace myns { // ... utf16_ostream& operator<<(utf16_ostream&, jstring) throw(std::bad_cast); utf16_ostream& operator<<(utf16_ostream&, const char *); utf16_ostream& operator<<(utf16_ostream&, const jni_utf16_string_region&); jni_utf16_ostream& operator<<(jni_utf16_ostream&, jstring); // ... } // namespace myns The implementation of jni_utf16_streambuf::overflow(int_type) is trivial. It just doubles the buffer width, puts the requested character, and sets the base, put, and end pointers correctly. It is tested and I am quite sure it works. The jni_utf16_ostream works fine inserting unicode characters. For example, this works fine and results in the stream containing "hello, world": myns::jni_utf16_ostream o(env); o << u"hello, wor" << u'l' << u'd'; My problem is as soon as I try to insert an integer value, the stream's bad bit gets set, for example: myns::jni_utf16_ostream o(env); if (o.badbit()) throw "bad bit before"; // does not throw int32_t x(5); o << x; if (o.badbit()) throw "bad bit after"; // throws :( I don't understand why this is happening! Is there some other method on std::basic_streambuf I need to be implementing????

    Read the article

  • Application doesn't start

    - by Jay
    Hello, I am having a rather strange problem, I deployed 2 .NET applications on my machine. Both run on v2.0. Now, while one of it works smoothly, the other one doesn't even start! Moreover, it doesn't throw any error, I couldn't see any error listings in the Event Viewer. Becoming hard to debug. On every other machine, both the exe's work perfectly fine! Any known issues? Thanks

    Read the article

  • Faces on WAS 6.1

    - by Nisse
    Hello, I'm running Java Facets on a IBM WebSphere 6.1. I'm getting this strange error message when I start the server: [2009-07-21 15:49:35:784 CEST] 00000015 ServletWrappe E SRVE0100E: Did not realize init() exception thrown by servlet Faces Servlet: java.lang.IllegalStateException: ApplicationAssociate ctor not called in same callstack as FacesConfigParser.contextInitialized(). Does anyone have an idea what's wrong?

    Read the article

  • using haskell for "business applications"

    - by snorlaks
    Hello, I would like to know if there is any posiibility that I can use Haskell with small database like sql server compact so that client wont have to install any server on his desktop. Is there any api providing sql statements and so on ... What is the best solution to achieve small database application using haskell. thanks for help

    Read the article

  • Is it possible to change UIBarButtonItem title and style in runtime?

    - by user262325
    Hello everyone In one project, I hope to change UIBarButtonItem and style in runtime editBarItemButton links to a UIBarButtonItem which original status are style:UIBarButtonItemStyleBordered title:Edit if I press the bar item button, it will execute the codes below: [editBarItemButton setStyle: UIBarButtonItemStyleDone]; [editTarBarItemButton setTitle:@"Done" ]; but neither the style nor title has changed. Welcome any comment Thanks interdev

    Read the article

  • Numerous buttons in a view

    - by mindfreak
    Hello, I want to create 25 buttons in my view. Should I create 25 buttons(UIbutton butonwithtype) individually or is there any other alternative ? Pl. comment if the Question is not understood by you.

    Read the article

  • [silverlight] Windows manager like mesh.com

    - by scrat789
    Hello, I would like du create a basic webdesktop in silverlight 4. How can I do a windows manager ? I want to move, resize, minimized, maximized each windows like http://mesh.com... Does it exist something to create easily a windows manager ? Do I have to create everything from scratch ? How ?

    Read the article

  • Errors in c++ faq lite?

    - by Gianluca
    Hello, I'm reading questions and answers around here for a few days. I have seen the c++ faq lite at Parashift has been mentioned many times. Personally I have always considered it to be a good reference, not my favourite one but certainly useful. Here I have seen somebody advising it, but many others commenting against it instead. Somebody mentioned it's full of mistakes. Could you please point out which are the major errors in there, if any?

    Read the article

  • Private heap or manage memory self

    - by Max
    Hello all, I know we could take some advantages from creating private heap of Windows especially for frequently allocated and de-allocated small chunks. But I think the normal approach is to allocate a large memory from default heap and manage the allocations and de-allocations ourselves. My question is which way is advantages and disadvantage between those two ways? Thanks, Max

    Read the article

  • ScrollView with scrollViews - what is the right way to do it?

    - by hveveris
    Hello! Client wants some tricky stuff and i don't really know where to start with it. The idea is that there is a horizontal scrollView whose each page consists of a vertical scrollView. For example, on the horizontal axis there are galleries, on the vertical we scroll through selected gallery's images. Is this even possible? I'd be very glad to hear comments on this one!

    Read the article

  • Is there any difference between Spring and Spring.net?

    - by Javi
    Hello, I've been using Spring with Java and I've seen that there is a version called Spring.NET. I wonder if there is any significant difference between them (apart from that one is for Java and the other is for .NET). Is it just a "language translation" of the framework or are they different project with just a similar purpose? Thanks.

    Read the article

  • How to configure the MembershipProvider in System.Web?

    - by Mickel
    Hello! In a project that I'm currently working on, we use the System.Web.Security MembershipProvider as our provider for membership and roles. Now, we do not only use this for a web application, but also a WCF & WPF application. So my question is: Where do I put the configuration of the MembershipProvider so that it applies for both web and WPF? The configuration I'm talking about is stuff like RequiresQuestionAndAnswer, RequiresUniqueEmail, PasswordFormat etc.

    Read the article

  • display tweets on iPhone

    - by Suresh Varma
    Hello people, I am developing an application where i have to display the tweets in the iPhone So i want to know whether it is possible or not? I have tried searching several posts but am unable to find one for iPhone. Kindly pass on the link if you get any.. Thanks in advance

    Read the article

  • Django admin, filter objects by ManyToMany reference

    - by Nick Z
    Hello! There's photologue application, simple photo gallery for django, implementing Photo and Gallery objects. Gallery object has ManyToMany field, which references Photo objects. I need to be able to get list of all Photos for a given Gallery. Is it possible to add Gallery filter to Photo's admin page? If it's possible, how to do it best?

    Read the article

< Previous Page | 281 282 283 284 285 286 287 288 289 290 291 292  | Next Page >