Search Results

Search found 6 results on 1 pages for 'plaisthos'.

Page 1/1 | 1 

  • Porting a select loop application to Android with NDK. Design question.

    - by plaisthos
    Hi, I have an network application which uses a select loop like this: bool shutdown=false; while (!shutdown) { [do something] select(...,timeout); } THe main loop cannot work like this in an Android application anymore since the application needs to receive Intents, need to handle GUI, etc. I think I have basically three possibilities: Move the main loop to the java part of the application. Let the loop run in its own thread and somehow communicate from/to java. Screw Android <= 2.3 and use a native activity and use AInputQueue/ALooper instead of select. The first possibility is not easy since java has no select which works on fds. Simply using the select and return after each loop to java is not an elegant possibility either since that requires setting the timeout to something like 20ms to have a good response time in the java part of the program. The second probability sound nicer but I have do some communication between java and the c++/c part of the program. Things that cold work: Using a socket, kind of ugly. using native calls in the "java gui thread" and callback from native in the "c thread". Both threads need to have thread safe implementations but this is managable. I have not explored the third possibility but I think that it is not the way to go. I think I can hack something together which will work but I asking what is the best path to chose.

    Read the article

  • Changing SQL Server Database sorting

    - by plaisthos
    I have a request to change the collation of a SQL Server Database: ALTER DATABASE solarwind95 collate SQL_Latin1_General_CP1_CI_AS but I get this strange error: Meldung 5075, Ebene 16, Status 1, Zeile 1 Das 'Spalte'-Objekt 'CustomPollerAssignment.PollerID' ist von 'Datenbanksortierung' abhängig. Die Datenbanksortierung kann nicht geändert werden, wenn ein schemagebundenes Objekt von ihr abhängig ist. Entfernen Sie die Anhängigkeiten der Datenbanksortierung, und wiederholen Sie den Vorgang. Sorry for the german errror message. I do not know how to switch the language to english, but here is a translation: Translation: Message 5075, Layer 16, Status 1, Row 1 The 'column' object 'CustomPollerAssignment.PollerID' depends on 'Database sorting. The database sorting cannot be changed if a schema bound object depends on it. Remove the dependency of the database sortieren and retry. I got a ton more of the errors like that.

    Read the article

  • Changing MSSQL Database sorting

    - by plaisthos
    I have a request to change the collation of a MS SQL Database: ALTER DATABASE solarwind95 collate SQL_Latin1_General_CP1_CI_AS but I get this strange error: Meldung 5075, Ebene 16, Status 1, Zeile 1 Das 'Spalte'-Objekt 'CustomPollerAssignment.PollerID' ist von 'Datenbanksortierung' abhängig. Die Datenbanksortierung kann nicht geändert werden, wenn ein schemagebundenes Objekt von ihr abhängig ist. Entfernen Sie die Anhängigkeiten der Datenbanksortierung, und wiederholen Sie den Vorgang. Sorry for the german errror message. I do not know how to switch the language to english, but here is a translation: Translation: Message 5075, Layer 16, Status 1, Row 1 The 'column' object 'CustomPollerAssignment.PollerID' depends on 'Database sorting. The database sorting cannot be changed if a schema bound object depends on it. Remove the dependency of the database sortieren and retry. I got a ton more of the errors like that.

    Read the article

  • Android NDK R5 and support of C++ exception

    - by plaisthos
    Hi, I am trying to use the NDK 5 full C++ gnustl: sources/cxx-stl/gnu-libstdc++/README states: This implementation fully supports C++ exceptions and RTTI. But all attempts using exceptions fail. An alternative NDK exists on http://www.crystax.net/android/ndk-r4.php. Even the hello-jni example from that site does not work. Compliation works after creating an Application.xml with APP_STL := gnustl_static But it dies the same horrific death as my own experiments. Am I am missing something or is the statement in the README just plain wrong?

    Read the article

  • C++: namespace conflict between extern "C" and class member

    - by plaisthos
    Hi, I stumbled upon a rather exotic c++ namespace problem: condensed example: extern "C" { void solve(lprec * lp); } class A { public: lprec * lp; void solve(int foo); } void A::solve(int foo) { solve(lp); } I want to call the c function solve in my C++ member function A::solve. The compiler is not happy with my intent: error C2664: 'lp_solve_ilp::solve' : cannot convert parameter 1 from 'lprec *' to 'int' Is there something I can prefix the solve function with? C::solve does not work

    Read the article

  • C++: namespace conflicht between extern "C" and class member

    - by plaisthos
    Hi, I stumbled upon a rather exotic c++ namespace problem: condensed example: extern "C" { void solve(lprec * lp); } class A { public: lprec * lp; void solve(int foo); } void A::solve(int foo) { solve(lp); } I want to call the c funcition solve in my C++ member function A::solve. The compiler is not happy with my intents: error C2664: 'lp_solve_ilp::solve' : cannot convert parameter 1 from 'lprec *' to 'int' Is there something I can prefix the solve function? C::solve does not work

    Read the article

1