Search Results

Search found 4319 results on 173 pages for 'native'.

Page 18/173 | < Previous Page | 14 15 16 17 18 19 20 21 22 23 24 25  | Next Page >

  • How to write native SQL queries in Hibernate without hardcoding table names and fields?

    - by serg555
    Sometimes you have to write some of your queries in native SQL rather than hibernate HQL. Is there a nice way to avoid hardcoding table names and fields and get this data from existing mapping? For example instead of: String sql = "select user_name from tbl_user where user_id = :id"; something like: String sql = "select " + Hibernate.getFieldName("user.name") + " from " + Hibernate.getTableName(User.class) + " where " + Hibernate.getFieldName("user.id") + " = :id";

    Read the article

  • Disable MOD_PHP in vhosts and activate suphp

    - by mezgani
    I need to desactivate mod_php on a vhost and let it working for other vhosts, I need to disable it in order to activate suphp. here is the vhost config : Options +Indexes ServerName www.native.org ServerAlias native.org DocumentRoot /home/user/www/native/current ServerAdmin [email protected] UseCanonicalName Off CustomLog /var/log/apache2/native_access.log combined ErrorLog /var/log/apache2/native_error.log <Directory /home/user/www/native/current> RemoveHandler .php AllowOverride All Options FollowSymLinks Order allow,deny allow from all </Directory> suPHP_Engine on SuexecUserGroup user native <IfModule mod_suphp.c> suPHP_UserGroup user native AddHandler x-httpd-php .php .php3 .php4 .php5 suPHP_AddHandler x-httpd-php </IfModule> NB: mod_php is activated by default for all vhosts

    Read the article

  • How to send native texture ptr from Unity web player to a browser plug-in?

    - by user2928039
    I have written an NPAPI browser plug-in (using Firebreath) that Unity uses to access Kinect camera. I can retrieve skeleton data from Unity through JavaScript easily since it isn't too big but the problem is in retrieving color image data. Is it possible to send a native texture pointer (GetNativeTexturePtr) from Unity through JavaScript into the C++ plug-in so that it can write the texture data directly? (tested in standalone version and it works) Any other suggestions on how to transfer image data from browser plug-ins to Unity web player are very welcome. Thanks.

    Read the article

  • What can I access in Androids Native libraries? And How?

    - by Donal Rafferty
    I am completely new to the NDK. I have done a couple of the tutorials including the hello from jni one and another one that calculates the sum of two numbers. They involved using cygwin and the ndk to create the library so file and I have a bit of a grasp on how to insert my own libraries into the libraries layer of Android. I have now been asked to access the native libraries on Android and see what I can use them for. My question is can I do this? The STABLE-APIS.txt document is a bit vague and mentions the following as Stable C++ API's in Android 1.5 cstddef new utility stl_pair.h Does that mean I can access them? If so then how do I go about it? I dont think that following the tutorials I have already done would be any help? Any pointers on how to do this or links to tutorials etc.. would be greatly appreciated

    Read the article

  • Best second language to learn for a native english speaking programmer?

    - by Tom Dignan
    I have always wanted to learn a foreign language, but I would like to pick one that can also help me the most in my career. I'm in the US, so it is not necessary for me to learn a second language to influence my career success, however I think knowing one and speaking it fluently could potentially put me in a more interesting career than if I did not. I would like to be able to travel the world, especially if I could have a reason to go one place or another. Which leads me to my question: What is the best second language to learn for a native English speaking programmer? (Especially from the US) Some ideas that come to mind for me are Mandarin, German, Japanese, French... I am looking for experienced opinions though! Thanks.

    Read the article

  • Mac-native text editor that can syntax-highlight diff files?

    - by strawtarget
    I do something like "svn diff /mystuff/current.diff". I want to view this .diff file with syntax highlighting. jEdit does it, but it's a huge beast and it takes a while to start up. I want something lightweight/native. Smultron/Fraise, TextWrangler, TextEdit, Dashcode don't seem to highlight .diff files. FileMerge seems to want to generate diff files, not show you existing ones. TextMate does the trick, but it's not free. I'd feel happier dropping $50 US if I was going to take advantage of it for anything more than a diff viewer. Are there any alternatives to jEdit or TextMate that I should consider?

    Read the article

  • Javascript functions return lines of function code or "{[native code]}," what am I doing wrong?

    - by DavidR
    I am writing some code to find the user selection in a contenteditable div, I'm taking my code from this quirksmode article. function findSelection(){ var userSelection; if (window.getSelection) {userSelection = window.getSelection;} else if (document.selection){userSelection = document.selection.createRange();} // For microsoft if (userSelection.text){return userSelection.text} //for Microsoft else {return userSelection} } I'm testing it in Chrome and Firefox, if I do an alert(userSelection) within the function or an alert(findSelection();) outside the function, it returns function getSelection() {[native code]}. If I do console.log(findSelection();) it gives me getSelection(). Is there something I've done wrong?

    Read the article

  • What languages allow cross-platform native executables to be created?

    - by JT
    I'm frustrated to discover that Java lacks an acceptable solution for creating programs that will run via double-click. Other than .NET for Windows, what modern and high-level programming languages can I write code in that can be compiled for various platforms and run as a native/binary in each (Windows, Linux, OSX (optional)) Assuming I wanted to write code in python, for instance, is there a cohesive way that I could distribute my software which wouldn't require users to do anything special to get it to run? I want to write and distribute software for computer-illiterate and Java has turned out to be a real pain in this respect.

    Read the article

  • Why Microsoft not provide for C# a static Win32 class with the most native functions and structures

    - by Oleg
    Everybody who used P/Invoke of Windows API knows a long list of declarations of static functions with attributes like [DllImport ("kernel32.dll", SetLastError = true, CharSet = CharSet.Auto)] The declaration of structures copied from Windows headers like WinNT.h or from web sites like www.pinvoke.net take also a lot of place in our programs. Why we all have to spend our time for this? Why Microsoft not give us a simple way to include a line like in old unmanaged programs #include <windows.h> and we would be have access to a static class Native with all or the most Windows functions and structures inside?

    Read the article

  • Raphael - what is the native delay function to draw circles?

    - by 3gwebtrain
    I am using Raphael, to draw 3 circles. how to i make the circles draw each one by one with some time gap? I know there is a option with settimeout, but apart from is there any native function to make delay to draw the circles? my simple code: <div id="paper"></div> var paper = Raphael('paper',500,500); var c1 = paper.circle(50,50,25); var c2 = paper.circle(100,50,25); var c3 = paper.circle(150,50,25); jsfiddle here

    Read the article

  • How do I fix "java.lang.OutOfMemoryError at sun.misc.Unsafe.allocateMemory(Native Method)"?

    - by Jephir
    I'm making a Java application that uses the Slick library to load images. However, on some computers, I get this error when trying to run the program: Exception in thread "main" java.lang.OutOfMemoryError at sun.misc.Unsafe.allocateMemory(Native Method) at java.nio.DirectByteBuffer.<init>(DirectByteBuffer.java:99) at java.nio.ByteBuffer.allocateDirect(ByteBuffer.java:288) at org.lwjgl.BufferUtils.createByteBuffer(BufferUtils.java:60) at org.newdawn.slick.opengl.PNGImageData.loadImage(PNGImageData.java:692) at org.newdawn.slick.opengl.CompositeImageData.loadImage(CompositeImageData.java:62) at org.newdawn.slick.opengl.CompositeImageData.loadImage(CompositeImageData.java:43) My VM options are: -Djava.library.path=lib -Xms1024M -Xmx1024M -XX:PermSize=256M -XX:MaxPermSize=256M The program loads a few large images (1024 x 768 resolution) at the beginning. Any help to solve this problem would be greatly appreciated.

    Read the article

  • What's causing "Unable to retrieve native address from ByteBuffer object"?

    - by r0u1i
    As a very novice Java programmer, I probably should not mess with that kind of things. Unfortunately, I'm using a library which have a method that accepts a ByteBuffer object and throws when I try to use it: Exception in thread "main" java.lang.NullPointerException: Unable to retrieve native address from ByteBuffer object Is it because I'm not using a non-direct buffer? edit: There's not a lot of my code there. The library I'm using is jNetPcap, and I'm trying to dump a packet to file. My code takes an existing packet, and extract a ByteBuffer out of it: byte[] bytes = m_packet.getByteArray(0, m_packet.size()); ByteBuffer buffer = ByteBuffer.wrap(bytes); Then it calls on of the dump methods of jNetPcap that takes a ByteBuffer.

    Read the article

  • How do you passthrough native SATA drives to a guest on ESXi?

    - by John
    I have ESXi 4.0 running on an Intel DX58S0 Mothboardboard with an Intel Core i7 930 processor. VT-d is also enabled. I have three drives in the system, drive 0 is used for ESXi. Drive 1 and 2 contain data from an older machine and show up under the "Storage Adapters" section in configuration. I would like to allow a guest machine to access the data on these drives (as nativly as possible). I have enabled passthrough of the motherboard's built in SATA controller (Intel/Marvell 88SE6121 ). This controller shows up in my guest OS, but the guest shows no drives aside from the normal virtual drive. I have tried a Linux guest and Windows7. I have also configured the host machine to try IDE/RAID/ACHI modes for the SATA controller. Any ideas how I can configure one of my guests to get at the raw data on these drives?

    Read the article

  • How do you passthrough native SATA drives to a guest on ESXi?

    - by John
    I have ESXi 4.0 running on an Intel DX58S0 Mothboardboard with an Intel Core i7 930 processor. VT-d is also enabled. I have three drives in the system, drive 0 is used for ESXi. Drive 1 and 2 contain data from an older machine and show up under the "Storage Adapters" section in configuration. I would like to allow a guest machine to access the data on these drives (as nativly as possible). I have enabled passthrough of the motherboard's built in SATA controller (Intel/Marvell 88SE6121 ). This controller shows up in my guest OS, but the guest shows no drives aside from the normal virtual drive. I have tried a Linux guest and Windows7. I have also configured the host machine to try IDE/RAID/ACHI modes for the SATA controller. Any ideas how I can configure one of my guests to get at the raw data on these drives?

    Read the article

  • Booting a native Windows install in Virtualbox: is it possible?

    - by Aron Rotteveel
    I am looking for something similiar to Bootcamp. Currently, I run Ubuntu Maveric as my primary operating system and run Windows 7 in Virtualbox. For some tasks, however, running Windows virtualized just seems to result in too much overhead and speed loss, and I'd like to be able to boot natively. The ideal situation would be to setup Windows and Ubuntu in dual boot on seperate partitions, with the ability to boot the Windows partition in Virtualbox on Ubuntu as well. Is this possible? Also, how it is that Bootcamp seems to be the only system capable of this?

    Read the article

  • where are user name and pasword saved in windows native vpn connection?

    - by Tîrêj
    I am using time freeze program but I can not save my free vpn user name and pasword. Since user name and pasword changed daily I have to unfreeze change pasword then freeze again. In the time freeze there is option to excusing file and folder. if I find the location of vpn setting that save the user name and pasword, I will have ability to use without unfreezing and re freezing. There is a location with path %userprofile%\AppData\Roaming\Microsoft\Network\Connections\Pbk\ that contain vpn configurations except user name and password. I need the location that store user name and password.

    Read the article

  • What would cause native gem extensions on OS X to build but fail to load?

    - by goodmike
    I am having trouble with some of my rubygems, in particular those that use native extensions. I am on a MacBookPro, with Snow Leopard. I have XCode 3.2.1 installed, with gcc 4.2.1. Ruby 1.8.6, because I'm lazy and a scaredy cat and don't want to upgrade yet. Ruby is running in 32-bit mode. I built this ruby from scratch when my MBP ran OSX 10.4. When I require one of the affected gems in irb, I get a Load Error for the gem extension's bundle file. For example, here's nokogigi dissing me: > require 'rubygems' = true > require 'nokogiri' LoadError: Failed to load /usr/local/lib/ruby/gems/1.8/gems/nokogiri-1.4.1/lib/nokogiri/nokogiri.bundle This is also happening with the Postgres pg and MongoDB mongo gems. My first thought was that the extensions must not be building right. But gem install wasn't throwing any errors. So I reinstalled with the verbose flag, hoping to see some helpful warnings. I've put the output in a Pastie, and the only warning I see is a consistent one about "passing argument n of ‘foo’ with different width due to prototype." I suspect that this might be an issue from upgrading to Snow Leopard, but I'm a little surprised to experience it now, since I've updated my XCode. Could it stem from running Ruby in 1.8.6? I'm embarrassed that I don't know quite enough about my Mac and OSX to know where to look next, so any guidance, even just a pointer to some document I couldn't find via Google, would be most welcome. Michael

    Read the article

  • osx rvm ruby 1.8.7 nokogiri 1.4.1 - ERROR: Failed to build gem native extension.

    - by tommasop
    I'm stuck with this problem. cat ~/.rvm/gems/ruby-1.8.7-p249/gems/nokogiri-1.4.1/ext/nokogiri/mkmf.log Gives this errors (clipped) conftest.c:3: error: 'xmlParseDoc' undeclared (first use in this function) conftest.c:3: error: (Each undeclared identifier is reported only once conftest.c:3: error: for each function it appears in.) For several libraries which are found in the system. If I manually go into ~/.rvm/gems/ruby-1.8.7-p249/gems/nokogiri-1.4.1/ext/nokogiri/ And compile and install everything goes fine ruby extconf.rb make make install mkdir -p /Users/tommasop/.rvm/rubies/ruby-1.8.7-p249/lib/ruby/site_ruby/1.8/i686-darwin9.8.0/nokogiri /usr/bin/install -c -m 0755 nokogiri.bundle /Users/tommasop/.rvm/rubies/ruby-1.8.7-p249/lib/ruby/site_ruby/1.8/i686-darwin9.8.0/nokogiri except that on script/server: ? script/server --debugger => Booting Mongrel => Rails 2.3.5 application starting on http://0.0.0.0:3000 ./script/../config/../vendor/rails/railties/lib/rails/gem_dependency.rb:119:Warning: Gem::Dependency#version_requirements is deprecated and will be removed on or after August 2010. Use #requirement The following gems have native components that need to be built nokogiri You're running: ruby 1.8.7.249 at /Users/tommasop/.rvm/rubies/ruby-1.8.7-p249/bin/ruby rubygems 1.3.6 at /Users/tommasop/.rvm/gems/ruby-1.8.7-p249, /Users/tommasop/.rvm/gems/ruby-1.8.7-p249%global Run `rake gems:build` to build the unbuilt gems. Any help greatly appreciated!

    Read the article

  • we would like the user to be able to pick a file from native file system and drag & drop it to our a

    - by user261740
    We have an existing java desktop application which starts, when user click on our application icon (placed on desktop) OR double click on executable(.exe). It opens the frame which allows user to select the file from native file system and uploads it to the server. Now we would like to facilitate user, that he can pick a file from windows explorer and drag it to the "shortcut / Application icon" & drop it on the "shortcut / Application icon" on the desktop. This would start the uploading of that file on the server. we need to capture the action of "drop" and launch on shortcut.. which may be completely not related to java, it can be very generic to any application. We are using JSmooth to build an executable from jar and NSIS for installer purpose. I would like to know.. How we can launch the application if user drops local file onto the system icon ? How we get the absolute path of file name which has been dropped onto the executable ?

    Read the article

  • Problems using (building?) native gem extensions on OS X

    - by goodmike
    I am having trouble with some of my rubygems, in particular those that use native extensions. I am on a MacBookPro, with Snow Leopard. I have XCode 3.2.1 installed, with gcc 4.2.1. Ruby 1.8.6, because I'm lazy and a scaredy cat and don't want to upgrade yet. Ruby is running in 32-bit mode. I built this ruby from scratch when my MBP ran OSX 10.4. When I require one of the affected gems in irb, I get a Load Error for the gem extension's bundle file. For example, here's nokogigi dissing me: > require 'rubygems' = true > require 'nokogiri' LoadError: Failed to load /usr/local/lib/ruby/gems/1.8/gems/nokogiri-1.4.1/lib/nokogiri/nokogiri.bundle This is also happening with the Postgres pg and MongoDB mongo gems. My first thought was that the extensions must not be building right. But gem install wasn't throwing any errors. So I reinstalled with the verbose flag, hoping to see some helpful warnings. I've put the output in a Pastie, and the only warning I see is a consistent one about "passing argument n of ‘foo’ with different width due to prototype." I suspect that this might be an issue from upgrading to Snow Leopard, but I'm a little surprised to experience it now, since I've updated my XCode. Could it stem from running Ruby in 1.8.6? I'm embarrassed that I don't know quite enough about my Mac and OSX to know where to look next, so any guidance, even just a pointer to some document I couldn't find via Google, would be most welcome. Michael

    Read the article

  • Is there a way to capture a bitmap from a WPF window using native C++?

    - by Mike Caron
    Imagine a document window in a MDI application which contains a child WPF window, say a sidebar for example. How can one get a bitmap containing both the WPF pixels AND the GDI (non-wpf) pixels? I've discovered that when making my thumbnail preview for the Win7 taskbar app icon hover, I get black in the parts of the preview where the WPF pixels should be. My current method simply grabs a bitmap capture of the document window. Then I get a DC for the preview, make a memory DC from it and select my bitmap into it. Then I do some size adjustments and bitblt the memory dc to the real dc. I'm guessing that the BitBlt operation doesn't take into account the fact that the WPF pixels are hardware accelerated and therefore need to be grabbed from the graphics hardware. All the stuff in GDI is managed just fine, though and when there's no WPF child windows, the preview image looks fine. I'm wondering if it's at all possible to grab a bitmap of the WPF window from native C++. Then I can blt that onto the black area of the previous preview.

    Read the article

< Previous Page | 14 15 16 17 18 19 20 21 22 23 24 25  | Next Page >