• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Swap jlong id[1] ?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Swap jlong id[1] ?


  • Subject: Re: Swap jlong id[1] ?
  • From: Eric Albert <email@hidden>
  • Date: Wed, 19 Apr 2006 19:48:36 +0100

On Apr 19, 2006, at 6:24 PM, rohit dhamija wrote:

Hi,
I am working on
Mac OS 10.4.5 PowerPC and Intel Mac
Xcode 2.2

Currently developing JNILib and need to swap data present in jlong id[1]


///// jlong id[1]; (*env)->GetLongArrayRegion(env, ident, 0, idsize, id); //////

Is there any swap routine provided for swapping long arrays ?

You mean that you need to byte-swap it? A jlong is a long long, so you can swap it with the 64-bit swapping functions in /usr/include/ libkern/OSByteOrder.h. To swap an array of them, call the byte- swapping function of your choice in a for loop.


Hope this helps,
Eric

_______________________________________________
Do not post admin requests to the list. They will be ignored.
Xcode-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Swap jlong id[1] ? (From: "rohit dhamija" <email@hidden>)

  • Prev by Date: Define text macro
  • Next by Date: Quick way to find files with additional compiler flags
  • Previous by thread: Swap jlong id[1] ?
  • Next by thread: Interface Builder: Images Tab - where do they come from
  • Index(es):
    • Date
    • Thread