Best method to reset a Point

Hello,
This is probably a mundane question but I am wondering what is the most efficient method to reset a Point.
1: Allocate a new Point
myPoint = new Point();
2: Set the point properties manually
myPoint.x = 0;
myPoint.y = 0;
3: Normalize its length
myPoint.normalize(0)
Any thoughts??
Pierre

Hi,
That is also my pick, but it is a pretty annoying thing to code for each reset. This is where a pre compiler and macro definition would be so usefull. I guess this is old school coding by today standard...who cares about performances.
Pierre

Similar Messages

  • XML in Oracle 9i (best method to return a xml file from a table query)

    Hello.
    What is the best method to query a table, or set of tables (that will return thousands of rows) using xml in oracle? (best performance)
    I'm currently using DBMS_XMLGen, is there a better method ?

    I think, if your talking about generating XML, that you should use XMLElement, XMLForest, etc. to create your XML.
    Lets assume that you base is relational data, then maybe the following great example will give you an idea how to do it : Re: Generate XML Schema from oracle tables
    As michaels pointed out (did you read the link/ URL given?), the general expectancy is that the packages will be less and less important. So also maintenance wise the XMLElement, etc way will be the best, also for the future, maintainable method.

  • F110:  What is best method in voiding an EFT payment after check run?

    What is the best method in voiding or reversing an EFT payment after a check run (F110)?
    Thanks!

    have you figureed it out?
    if I didn't remember wrong, we first find the clearing document number in proposal log, and used FBRA to reset the clearing items, then reverse the document
    I am also interested in setting a dummy check number for EFT, anyone can throw some ideas here?
    thanks
    Keqin

  • What is the best technique for resetting a view?

    I was wondering what is the best technique for resetting the initial state of a view?
    I am creating a form and want to provide a reset button for the user.  I could write an initialize() method that my action handler calls, but I am wondering if the framework already provides this functionality in a more elegant way.
    If I write an initialize method, then I have to manually populate my fields with my context mappings in my initialize() code to mimic what happens automatically by the framework the first time the view is called.  This seems prone to error since this is duplicating the mapping logic.
    Michael

    Hi,
    Even though it boils down to the same logic, for consistency sake it is good to have the initialization logic coded in the inbound plug method and then to call the outbound plug on reset.This make more sense when you have multiple navigation possible to the same view through multiple inbound plugs.
    Else, have an initialization method.
    PS: check whether the reset() method of IWDContext make sense. This is helpful when you have remove dynamically added nodes and attributes.
    Thanks and Regards,
    Sam Mathew

  • What is the best method for moving iTune Libraries from Old to New Computer

    Hello,
    Thanks in advance for any assistance you may offer.
    My Sony Vaio Desktop recently died and untimely death, so I just purchased an HP Notebook. I was trying to wait out the release of the possible update of the Macbook line. However the old computer didn't agree. This HP will tie me over till a new release.
    I've been doing weekly backups for over 3 years with a backup drive from Western Digital. At this point I just want to transfer my music in iTunes and applications from the App store that are loaded on to my iPod Touch into the new computer and then reauthorize and sync.
    My question is what's the best method. Oh another problem I'm having includes the latest iPhone & iPod Touch software problem of 3rd party apps not working along with the vanishing of my music on the Touch.
    Any guidance would be much appreciated.

    Open up a fresh copy of iTunes. Point iTunes in the direction of your Western Digital Harddrive. Import Folders.
    1. New Copy
    2. Edit -> Preferences -> Advanced -> General -> Change -> <the address of the iTunes library on WD>
    3. File -> Add Folder to Library -> <Select iTunes folder on WD>
    Always keep a backup of your iTunes Library file and the iTunes XML Document. If you have those, then it might be just as simple as copying those to your iTunes file folder. If you are not sure where they are, then do a search for iTunes.xml.

  • Best method for incremental replication to backup xserve?

    I was just trying to figure out what would be the best method for routinely incrementally replicating a primary xserve. I have a secondary that has the same hardware. I thought about using scheduled tasks with Carbon Copy Cloner over say a Crossover cable to the secondary xserve. However, doing this backup would continually wipe out the network settings for the secondary mac? I could do the replication to a secondary drive and then just make that drive the boot drive in the event of data corruption on the master server?
    Where I'm at now is that the primary server runs Raid1, so in the event of a single drive failure or a hardware failure, I could swap the drives into the backup server. However, I'd like some sort of protection against data corruption on the primary xserve.
    Any general thoughts on a better way to do this? Or is there software that does this well?
    Thanks

    Our primary is an XServe RAID. In addition it has an external 2TB drive that I CCC all the user accounts to every night. I then setup a Mac Mini Server as a replica.
    If the primary XServe has a catastrophic failure, I simply connect the 2TB drive to the Mac Mini and point the replicated user accounts to the cloned data on the 2TB drive.
    I haven't tested it. But this scenario seemed like the best solution.
    Message was edited by: MacTech_09

  • Best method for refreshing a component's data?

    What's better when you want to refresh the content of an object? Should you just replace your JComponent with an entirely new one, or should you try to get access to the data and then remove the items and then re-add them.
    In my example, I have a JTree and am not sure which would be the best method to use. Should I try to remove all the nodes, or sometimes I think it would be easier to just remove the tree component from my panel, create a new tree and re-populate it?
    Thanks for any advice.

    pjbarbour wrote:
    I'm not quite sure what would be the best method for this.  My client is using a 4x3 screen and SD projector at a large meeting, and they want me to just create a DVD that is letterboxed.  I have one Premiere CS5 project that's 1920x1080, and another project that's 720x480 widescreen (1.2).  I created a new sequence in both projects that is 720x480, 4x3 (0.9), and what I do is just scale the timeline down so that it's letterboxed.  Is this the best method for achieving this?  Or would you do something else?  I don't like the idea of scaling my timeline down in Premiere.
    Hello.
    As Jim so rightly points out above, you do not need to do anything.
    Just use your normal 16:9 widescreen footage, and author as normal.
    Your player will letterbox automatically when it is connected to a 4:3 screen in setup (just make sure "Pan & Scan" is not also there)

  • Best method for archiving .mpp files on a separate server or location?

    We want to be able to run a program or job on Project Server 2013 that will export all current published project .mpp files to a separate server or location on our network. What is the best, or suggested, method for something like this? Our managers want
    to have this job run on a weekly or bi-monthly basis in order to have backup files of each active project schedule. This would be beyond the Project Server archive database. This would be for Business Continuity purposes of having those schedules available
    should our servers ever crash. 
    Any help would be much appreciated. I am not a developer, but if there is code available for something like this we have developers in-house that can perform the work. 
    Thank you,
    Travis
    Travis Long IT Project Manager Entry Idaho Power Co. Project Server Admin

    Project server already has an archiving mechanism which backs up project plans based on schedule and maitains versions of it which can be restored at any point ? check administrative backup in central Admin under PWA settings
    However I wouldn't say this is the best method, but you can run a macro which would export all projects and save it at a location(could be network file share), Something like this (havent tested it recently with 2013 but i believe should work
    Sub Archiving()
    Dim Conn As New ADODB.Connection
    Dim Cmd As New ADODB.Command
    Dim Recs As New ADODB.Recordset
    'Connect to Project Server Reporting DB, Get Project Names
    Conn.ConnectionString = "Provider=SQLOLEDB;Data Source=servername;Initial Catalog=ProjectServer_Reporting;User ID=; Password=; Trusted_Connection=yes"
    Conn.Open
    With Cmd
        .ActiveConnection = Conn
        .CommandText = "Select ProjectName From MSP_EpmProject_UserView"
        .CommandType = adCmdText
    End With
     With Recs
        .CursorType = adOpenStatic
        .CursorLocation = adUseClient
        .LockType = adLockOptimistic
        .Open Cmd
      End With
    Dim prjName As String
    Dim ArchivePrjName As String
    Application.Alerts (False)
    If Recs.EOF = False Then
       Recs.MoveFirst
       For x = 1 To CInt(Recs.RecordCount)
        prjName = "<>\" + Recs.Fields(0)
        FileOpenEx Name:=prjName, ReadOnly:=True
        ArchivePrjName = "C:\Temp\" & prjName & "4Sep2014_9PM"
        FileSaveAs Name:=ArchivePrjName, FormatID:="MSProject.MPP"
        FileCloseEx
        prjName = ""
        Recs.MoveNext
       Next x
    End If
       Recs.Close
       Conn.Close
    End Sub
     Let us know if this helps
    Thanks | epmXperts | http://epmxperts.wordpress.com

  • Best Method for Strechable .swf file in horizontal but not vertical?

    What is the best method to create an easy to use flash file
    that will allow horizontal scaling with a fixed vertical size?
    This will be for a blog header in a variable width design at
    Make Light Real.com
    I have tried the basic stage properties and found
    StageScaleMode.NO_BORDER to be an ok solution, but I'm not
    sure what will happen when I begin to drop active clips in on the
    stage. Will the stage operate from a fixed point or how will the
    clips orient to the stage as it expands?
    My understanding of actionscript is just enough to hack
    pieces of what I need together: but if you could enlighten me with
    the most basic understanding of which method would work best for me
    I'd apprecate it. I also have this method to alter the background
    (as a clip):
    quote:
    Stage.addListener(ecout);
    // function which replaces all the elements with the new
    values
    slide = function () {
    photo_mc._x = 0;
    photo_mc._y = 0;
    photo_mc._width = Stage.width;
    photo_mc._height = Stage.width/rapp;
    if (photo_mc._height<Stage.height) {
    photo_mc._height = Stage.height;
    photo_mc._width = Stage.height*rapp;
    slide()
    Should I just alter the variables there to lock the stage
    height?
    Thanks for your time in answering.

    When you export your movie you can select the scaling options
    for width and height.
    Try selecting one but not the other.
    Cheers,
    Gorka
    http://www.AquiGorka.com/blog

  • Best method for keyframing with 3d camera 1 shot....

    Hi I have a project I am working on and basically I am finding the key framing a little frustrating because I cant get the camera to do what I want. Ususally I have no problem in FCP but with Motion it doesnt seem as easy. Bascially what I have done is put up 7 of the same clip all in 3d spread down. What I want the camera to do is zoom close to one. Pause while you read what is on the clip then pan and zoom to the next one. The method I am doing is I hit the record button. Start the zoom to the first object then move timeline to where I want the camera to stop the zoom. I hit the record button again..wait a few frames and then hit it again so I can zoom to the next object. What seems to hahppen is the camera just starts moving to the other object and wont pause for those frames. I would like to know the best method for making this possible.Thanks

    hi,
    edit them all! Just select them all and choose linear from the control pop up.
    if that doesnt work, maybe you could try setting keyframes manually, like you would in FCP. You dont turn on the red button at all, but add keframes for the parameters you want to animate in the Inspector window.
    Sometimes I find I have to add two keyframes a frame apart to give that definite stop. This also allows me to play with the timing of the pauses. So set a keyframe where the camera starts to move and one where it stops. Then a frame on set another keyframe without changing the values, then go to the next point you want the camera to move and set another keyframe.... and so on.
    hth
    adam

  • Best method for UIComponent Initialization?

    I have a custom class that extends Panel and I would like to
    get input on the best method for initializing custom properties
    upon object creation. I currently create an event handler for the
    FlexEvent.CREATION_COMPLETE event and assign my properties then.
    However, I'd like to slim my code down. Is there a place I
    can initialize properties without having to import events? I tried
    overriding some protected methods such as commitProperties, but
    discovered this method gets called again by Flex when effects are
    done playing on the UIComponent. I don't want to initialize my
    custom parameters again because this is essentially reseting any
    interaction the user did with it.
    Is there another super method I can use to initialize my
    method rather than use CREATION_COMPLETE events?
    Thanks.

    The simplest and cheapest option is LifeFlix.  They have more info at www.lifeflix.com or on the Mac app store at https://itunes.apple.com/us/app/lifeflix/id630212114?ls=1&mt=12

  • Best method for networking with ubuntu linux

    Hi,
    I'm setting up an ubuntu linux fileserver, and I was wondering what the best method for filesharing with my mac is. I'm currently running osx 10.4.11, though I may be upgrading to 10.5 soon. I'll be running SMB networking for a couple of other computers, but I'd prefer something a bit more robust that can handle file permissions etc.

    Mac OS X supports NSF out of the box. Configuration isn't documented.
    I recall Apple got rid of net info manager in Leopard, so the configuration will be different. Perhaps more unix like.
    Mac OS X support the Unix Network File System (NFS). However, it leaves out
    the GUI.
    This page show you how to use NetInfo Manager:
    http://mactechnotes.blogspot.com/2005/09/mac-os-x-as-nfs-server.html#c1168221713 40271068
    NFS Manager can both setup NFS shares and connect to NFS shares.
    http://www.bresink.com/osx/NFSManager.html
    Once you figure out how NFS Manager configures the NFS shares, you can
    use Applications > Utilities > NetInfo Manager to create more shares.
    You will either have to coordinate Unix Userid number and Unix Group Id number or use the mapall option on the share.
    To find out your Mac OS X userid and group id do:
    applications > utilities > terminal
    ls -ln
    ls -l
    # lists the NFS share on your mac
    showmount -e localhost
    #list NFS shares on a remote host
    showmount -e remote-ip-address
    Once you see what NFS Manager does, you will be able to use NetInfo Manager to manage a connection. In Mac OS 10.4 you can configure the /etc/exports control file. See man exports for the details. Before that you had to have the data in NetInfo manager. When Mac OS X came out, many common Unix control files were not present. Instead the data had to be in NetInfo manager. Over time Apple has added more and more standard Unix control files.
    ======
    You do know about the need to match userids & groupids.
    # display uid and gid
    ls -ln
    sudo find / -user short-user-name -exec ls '-l' {} \;
    # on Mac OS X
    you will need to go into NetInfo Manager and select user and find your short-user-name. Change uid and guid.
    #on Linux look in
    /etc/passwd
    /etc/group
    # with care...
    # change 1000:20 to your values for uid:gid
    sudo find / -user short-user-name -exec chown 1000:20 {} \;
    The manual for Tenon MachTen UNIX (which Apple checked when doing Mac OS
    X) says that one should crate the file /etc/exports, which will cause
    portmap, mountd and nsfd to launch at startup via the /etc/rc file. The
    file must not contain any blank lines or comments, and each line has the
    syntax
    directory -option[, option] hostlist
    where 'directory is the pathname of the directory that can be exported,
    and 'hostlist' is a space separated list of hostnames that can access the
    directory. For example
    /usr -ro foo bar
    /etc
    /Applications
    /User/gladys gladys
    The client the uses a command like
    /sbin/mount -t type [-rw] -o [options] server:directory mount_point
    where 'type' is 'nfs', 'server' the name of the server, 'directory' the
    server directory mounted, and 'mount_point' the client mount point. See
    'man mount' for details.
    I haven't tried the above, but it would be nice to know if it works on Mac OS X.
    Hans Aberg
    This will give you some hints on NFS. Post back your questions.
    Robert

  • Best Method for converting a 16x9 video to a letterboxed 4x3 DVD

    I'm not quite sure what would be the best method for this.  My client is using a 4x3 screen and SD projector at a large meeting, and they want me to just create a DVD that is letterboxed.  I have one Premiere CS5 project that's 1920x1080, and another project that's 720x480 widescreen (1.2).  I created a new sequence in both projects that is 720x480, 4x3 (0.9), and what I do is just scale the timeline down so that it's letterboxed.  Is this the best method for achieving this?  Or would you do something else?  I don't like the idea of scaling my timeline down in Premiere.

    pjbarbour wrote:
    I'm not quite sure what would be the best method for this.  My client is using a 4x3 screen and SD projector at a large meeting, and they want me to just create a DVD that is letterboxed.  I have one Premiere CS5 project that's 1920x1080, and another project that's 720x480 widescreen (1.2).  I created a new sequence in both projects that is 720x480, 4x3 (0.9), and what I do is just scale the timeline down so that it's letterboxed.  Is this the best method for achieving this?  Or would you do something else?  I don't like the idea of scaling my timeline down in Premiere.
    Hello.
    As Jim so rightly points out above, you do not need to do anything.
    Just use your normal 16:9 widescreen footage, and author as normal.
    Your player will letterbox automatically when it is connected to a 4:3 screen in setup (just make sure "Pan & Scan" is not also there)

  • Best method for rounded corners?

    Hi all,
    Can someone please share the best method for creating rounded corners similar to the menu interface in Leopard? Actually the best representation I've seen, is in the Motion 3 Tutorials - Working with 3D. The Matte Shape filter in FCP is close, but not quite the cigar I'm looking for.
    Thanks!

    Hi Jim,
    • Select Clip
    • Add 4 point Garbage Matte
    • Activate all 4 corners by clicking on the labels 1-4
    • Adjust settings to your desires.
    As an example I used:
    • Smooth = 12
    • Choke = -47
    • Feather = 2
    Worked like a charm.

  • Best method for controlling Office 365 updates

    Were looking for the best method for updating Office 365. We will be testing prior to releasing the version to the rest of the company.  We have a couple of methods we're contemplating but looking for any pros or cons for each.  We are also
    using SCCM 2012.
    1. Run setup.exe setting the version and internal install source in an .xml file run as an SCCM package using distribution points as the install source.
    2. Run click2runclient.exe with command lines setting the version and internal install source as an SCCM package using distribution points as the install source.
    3  Set the version through group policy and turn on automatic updates and don't specify an install source.
    Option 3 appears to be the most straight forward with the least administrative overhead.  Would it be possible to revert back to an earlier version using this method?
    I have read various articles but looking for any input as to what is working well  or not working for others.

    Hi,
    I would like to share this
    blog post with you, which provides an example how to implement a fully automated testing and deployment process of Office 365 updates. This deployment method provides you the ability to test updates before you approve them in my environment.
    The process might look like:
    Deploy Office 365 in your environment with Office Deployment Tool, configure the "Updates" element in the configuration.xml file so that updates are enabled and the "UpdatePath" attribute points to an internal source.
    Download the latest Office 365 build into a different internal source, configure your test machine to pick up builds from it.
    After testing the updates, copy the updates to the first internal source.
    You should be able to integrate the process with SCCM to reduce your administrative effort.
    Hope this helps.
    Regards,
    Ethan Hua
    TechNet Community Support
    It's recommended to download and install
    Configuration Analyzer Tool (OffCAT), which is developed by Microsoft Support teams. Once the tool is installed, you can run it at any time to scan for hundreds of known issues in Office
    programs.
    Please remember to mark the replies as answers if they help, and unmark the answers if they provide no help. If you have feedback for TechNet Support, contact [email protected]

Maybe you are looking for