java.awt.geom

Class Point2D.Float

    • Field Summary

      Fields 
      Modifier and Type Field and Description
      float x
      The X coordinate of this Point2D.
      float y
      The Y coordinate of this Point2D.

        

    • Constructor Summary

      Constructors 
      Constructor and Description
      Point2D.Float()
      Constructs and initializes a Point2D with coordinates (0, 0).
      Point2D.Float(float x, float y)
      Constructs and initializes a Point2D with the specified coordinates.

        

    • Field Detail

      • x

        public float x
        The X coordinate of this Point2D.
        Since:
        1.2
      • y

        public float y
        The Y coordinate of this Point2D.
        Since:
        1.2
    • Constructor Detail

      • Point2D.Float

        public Point2D.Float()
        Constructs and initializes a Point2D with coordinates (0, 0).
        Since:
        1.2
      • Point2D.Float

        public Point2D.Float(float x,
                     float y)
        Constructs and initializes a Point2D with the specified coordinates.
        Parameters:
        x - the X coordinate of the newly constructed Point2D
        y - the Y coordinate of the newly constructed Point2D
        Since:
        1.2
    • Method Detail

      • getX

        public double getX()
        Returns the X coordinate of this Point2D in double precision.
        Specified by:
        getX in class Point2D
        Returns:
        the X coordinate of this Point2D.
        Since:
        1.2
      • getY

        public double getY()
        Returns the Y coordinate of this Point2D in double precision.
        Specified by:
        getY in class Point2D
        Returns:
        the Y coordinate of this Point2D.
        Since:
        1.2
      • setLocation

        public void setLocation(double x,
                       double y)
        Sets the location of this Point2D to the specified double coordinates.
        Specified by:
        setLocation in class Point2D
        Parameters:
        x - the new X coordinate of this Point2D
        y - the new Y coordinate of this Point2D
        Since:
        1.2
      • setLocation

        public void setLocation(float x,
                       float y)
        Sets the location of this Point2D to the specified float coordinates.
        Parameters:
        x - the new X coordinate of this Point2D
        y - the new Y coordinate of this Point2D
        Since:
        1.2
      • toString

        public String toString()
        Returns a String that represents the value of this Point2D.
        Overrides:
        toString in class Object
        Returns:
        a string representation of this Point2D.
        Since:
        1.2

Traduction non disponible

Les API Java ne sont pas encore traduites en français sur l'infobrol. Seule la version anglaise est disponible pour l'instant.

Document créé le 02/08/2006, dernière modification le 04/03/2020
Source du document imprimé : https://www.gaudry.be/java-api-rf-java/awt/geom/Point2D.Float.html

L'infobrol est un site personnel dont le contenu n'engage que moi. Le texte est mis à disposition sous licence CreativeCommons(BY-NC-SA). Plus d'info sur les conditions d'utilisation et sur l'auteur.

Références

  1. Consulter le document html Langue du document :fr Manuel PHP : https://docs.oracle.com, Point2D.Float

Ces références et liens indiquent des documents consultés lors de la rédaction de cette page, ou qui peuvent apporter un complément d'information, mais les auteurs de ces sources ne peuvent être tenus responsables du contenu de cette page.
L'auteur de ce site est seul responsable de la manière dont sont présentés ici les différents concepts, et des libertés qui sont prises avec les ouvrages de référence. N'oubliez pas que vous devez croiser les informations de sources multiples afin de diminuer les risques d'erreurs.

Table des matières Haut