Skip to content

Conversation

@oboudou
Copy link
Contributor

@oboudou oboudou commented Oct 5, 2018

No description provided.

"recherchée est un objet définissant l'une des méthodes de descripteur, "
"Python peut substituer le comportement par défaut et appeler à la place la "
"méthode Descriptor. Lorsque cela se produit dans la chaîne de précédence "
"dépend de quelles méthodes descripteur ont été définies."

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

peut-etre un s a descripteur dans la ligne 107

"different calls to :meth:`__get__`."
msgstr ""
":méth:`objet.__getattribute__` et :méth:`type.__getattribute__` font "
"différents appels à:méth:`__get__`."

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

il manque un espace apres à

#: ../Doc/howto/descriptor.rst:3
msgid "Descriptor HowTo Guide"
msgstr ""
msgstr "Descripteur Guide HowTo"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Guide pour l'utilisation des descripteurs ?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

merci

"methods. Shows how each works by giving a pure Python equivalent and a "
"sample application."
msgstr ""
"Définit les descripteurs, résume le protocole et montre comment les "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Je ne sais pas si l'on est obligé de coller au style télégraphique de Raymond. There must be a better way ! et je tape du poing sur la table.
Bref, je pense que l'on peut construire de vraies phrases

"En général, un descripteur est un attribut objet avec un \"comportement "
"contraignant\", dont l'accès à l'attribut a été remplacé par des méthodes "
"dans le protocole du descripteur. Ces méthodes sont : :méth:`__get__`, :"
"méth:`__set__`, et :méth:`__delete__`. Si l'une de ces méthodes est définie "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

En français, il est d'usage de ne pas mettre de virgule avant le 'et'.

msgstr ""
"Le comportement par défaut pour l'accès aux attributs consiste à obtenir, "
"définir ou supprimer l'attribut du dictionnaire d'un objet. Par exemple, ' "
"'a. x' 'a une chaîne de recherche commençant par' 'a. __dict__ ['x'] ' ', "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

pour 'a.x', Python commence par rechercher dans ...

"Le comportement par défaut pour l'accès aux attributs consiste à obtenir, "
"définir ou supprimer l'attribut du dictionnaire d'un objet. Par exemple, ' "
"'a. x' 'a une chaîne de recherche commençant par' 'a. __dict__ ['x'] ' ', "
"puis' 'type (a). __dict__ ['x'] ' ', et continuant à travers les classes de "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

... puis continue en cherchant dans les classes ....

"base de' 'type (a) ' 'À l'exclusion des sous-classes. Si la valeur "
"recherchée est un objet définissant l'une des méthodes de descripteur, "
"Python peut substituer le comportement par défaut et appeler à la place la "
"méthode Descriptor. Lorsque cela se produit dans la chaîne de précédence "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

la méthode correspondante du descripteur. Le moment où ce comportement est adopté dépend de la chaîne de précédence et des endroits où les méthodes descripteur ont été définies.

"L'objet retourné par ``super()`` a aussi une méthode personnalisée :meth:"
"`__getattribute__` pour appeler les descripteurs. L'appel ``super(B, obj)."
"m()`` recherche ``obj.__class__.__mro__`` pour la classe de base ``A`` "
"immédiatement après ``B`` et retourne ensuite ``A.__dict__['m'].__get__(obj, "
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

La documentation française préfère "renvoie" à "retourne" (voir glossaire).

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

merci

@JulienPalard JulienPalard merged commit 740eb9c into python:3.7 Oct 5, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

4 participants