diff --git a/dictionaries/library_types.txt b/dictionaries/library_types.txt new file mode 100644 index 0000000000..8ae005266b --- /dev/null +++ b/dictionaries/library_types.txt @@ -0,0 +1,5 @@ +getattr +enrutará +AttributeError +Enum +corutina \ No newline at end of file diff --git a/library/types.po b/library/types.po index 1750ddc135..4e3b30fe3a 100644 --- a/library/types.po +++ b/library/types.po @@ -6,33 +6,38 @@ # Check https://github.com/PyCampES/python-docs-es/blob/3.8/TRANSLATORS to # get the list of volunteers # -#, fuzzy msgid "" msgstr "" "Project-Id-Version: Python 3.8\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2020-05-05 12:54+0200\n" -"PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" -"Last-Translator: FULL NAME \n" +"PO-Revision-Date: 2020-07-28 22:07-0500\n" "Language-Team: python-doc-es\n" "MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=utf-8\n" +"Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: 8bit\n" "Generated-By: Babel 2.8.0\n" +"Plural-Forms: nplurals=2; plural=(n != 1);\n" +"Last-Translator: \n" +"Language: es\n" +"X-Generator: Poedit 2.4\n" #: ../Doc/library/types.rst:2 msgid ":mod:`types` --- Dynamic type creation and names for built-in types" msgstr "" +":mod:`types` --- Creación de tipos dinámicos y nombres para tipos integrados" #: ../Doc/library/types.rst:7 msgid "**Source code:** :source:`Lib/types.py`" -msgstr "" +msgstr "**Código fuente:** :source:`Lib/types.py`" #: ../Doc/library/types.rst:11 msgid "" "This module defines utility functions to assist in dynamic creation of new " "types." msgstr "" +"Este módulo define funciones de utilidad para ayudar en la creación dinámica " +"de tipos nuevos." #: ../Doc/library/types.rst:14 msgid "" @@ -40,20 +45,27 @@ msgid "" "Python interpreter, but not exposed as builtins like :class:`int` or :class:" "`str` are." msgstr "" +"Este también define nombres para algunos tipos de objetos que son utilizados " +"por el intérprete estándar de Python, pero no expuestos como integrados como " +"lo son :class:`int` o :class:`str`." #: ../Doc/library/types.rst:18 msgid "" "Finally, it provides some additional type-related utility classes and " "functions that are not fundamental enough to be builtins." msgstr "" +"Por último, este proporciona algunas clases de utilidad y funciones " +"adicionales relacionadas con tipos que no son lo suficientemente " +"fundamentales como para ser integradas." #: ../Doc/library/types.rst:23 msgid "Dynamic Type Creation" -msgstr "" +msgstr "Creación dinámica de tipos" #: ../Doc/library/types.rst:27 msgid "Creates a class object dynamically using the appropriate metaclass." msgstr "" +"Crea un objeto de clase dinámicamente utilizando la metaclase adecuada." #: ../Doc/library/types.rst:29 msgid "" @@ -61,6 +73,9 @@ msgid "" "header: the class name, the base classes (in order), the keyword arguments " "(such as ``metaclass``)." msgstr "" +"Los tres primeros argumentos son los componentes que componen un encabezado " +"de definición de clase: el nombre de la clase, las clases base (en orden), " +"los argumentos por palabra clave (tal como ``metaclass``)." #: ../Doc/library/types.rst:33 msgid "" @@ -69,10 +84,15 @@ msgid "" "argument and update the namespace directly with the class contents. If no " "callback is provided, it has the same effect as passing in ``lambda ns: ns``." msgstr "" +"El argumento *exec_body* es una retrollamada que se usa para rellenar el " +"espacio de nombres de clase recién creado. Debe aceptar el espacio de nombre " +"de clase como su único argumento y actualizar el espacio de nombre " +"directamente con el contenido de la clase. Si no se proporciona ninguna " +"retrollamada, tiene el mismo efecto que pasar ``lambda ns: ns``." #: ../Doc/library/types.rst:43 msgid "Calculates the appropriate metaclass and creates the class namespace." -msgstr "" +msgstr "Calcula la metaclase adecuada y crea el espacio de nombre de clase." #: ../Doc/library/types.rst:45 msgid "" @@ -80,10 +100,13 @@ msgid "" "class name, the base classes (in order) and the keyword arguments (such as " "``metaclass``)." msgstr "" +"Los argumentos son los componentes que constituyen un encabezado de " +"definición de clase: el nombre de la clase, las clases base (en orden) y los " +"argumentos de palabra clave (como ``metaclass``)." #: ../Doc/library/types.rst:49 msgid "The return value is a 3-tuple: ``metaclass, namespace, kwds``" -msgstr "" +msgstr "El valor retornado es una tupla de 3: ``metaclass, namespace, kwds``" #: ../Doc/library/types.rst:51 msgid "" @@ -92,6 +115,10 @@ msgid "" "with any ``'metaclass'`` entry removed. If no *kwds* argument is passed in, " "this will be an empty dict." msgstr "" +"*metaclass* es la metaclase adecuada, *namespace* es el espacio de nombre de " +"clase preparado y *kwds* es una copia actualizada del pasado en el argumento " +"*kwds* con cualquier entrada ``'metaclass'`` eliminada. Si no se pasa ningún " +"argumento *kwds*, será un diccionario vacío." #: ../Doc/library/types.rst:60 msgid "" @@ -99,26 +126,32 @@ msgid "" "changed. Now an insertion-order-preserving mapping is used when the " "metaclass does not have a ``__prepare__`` method." msgstr "" +"El valor predeterminado para el elemento ``namespace`` de la tupla retornada " +"ha cambiado. Ahora una asignación de inserción-orden-conservación es " +"utilizada cuando la metaclase no tiene un método ``__prepare__``." #: ../Doc/library/types.rst:67 msgid ":ref:`metaclasses`" -msgstr "" +msgstr ":ref:`metaclasses`" #: ../Doc/library/types.rst:67 msgid "Full details of the class creation process supported by these functions" msgstr "" +"Detalles completos del proceso de creación de clases soportado por estas " +"funciones" #: ../Doc/library/types.rst:69 msgid ":pep:`3115` - Metaclasses in Python 3000" -msgstr "" +msgstr ":pep:`3115` - Metaclases en Python 3000" #: ../Doc/library/types.rst:70 msgid "Introduced the ``__prepare__`` namespace hook" -msgstr "" +msgstr "Se presenta el *hook* de espacio de nombres ``__prepare__``" #: ../Doc/library/types.rst:74 msgid "Resolve MRO entries dynamically as specified by :pep:`560`." msgstr "" +"Resuelve las entradas MRO dinámicamente según lo especificado por :pep:`560`." #: ../Doc/library/types.rst:76 msgid "" @@ -129,14 +162,20 @@ msgid "" "doesn't have an ``__mro_entries__`` method, then it is included in the " "return tuple unchanged." msgstr "" +"Esta función busca elementos en *bases* que no son instancias de :class:" +"`type` y retorna una tupla donde cada uno de estos objetos que tiene un " +"método ``__mro_entries__`` se reemplaza con un resultado desempaquetado de " +"llamar a este método. Si un elemento *bases* es una instancia de :class:" +"`type` o no tiene un método ``__mro_entries__``, se incluye en el retorno la " +"tupla sin cambios." #: ../Doc/library/types.rst:87 msgid ":pep:`560` - Core support for typing module and generic types" -msgstr "" +msgstr ":pep:`560` - Soporte principal para módulos de tipo y tipos genéricos" #: ../Doc/library/types.rst:91 msgid "Standard Interpreter Types" -msgstr "" +msgstr "Tipos de Intérpretes Estándar" #: ../Doc/library/types.rst:93 msgid "" @@ -145,50 +184,66 @@ msgid "" "types that arise only incidentally during processing such as the " "``listiterator`` type." msgstr "" +"Este módulo proporciona nombres para muchos de los tipos necesarios para " +"implementar un intérprete de Python. Esto evita deliberadamente incluir " +"algunos de los tipos que surgen sólo accidentalmente durante el " +"procesamiento, tal como el tipo ``listiterator``." #: ../Doc/library/types.rst:98 msgid "" "Typical use of these names is for :func:`isinstance` or :func:`issubclass` " "checks." msgstr "" +"El uso típico de estos nombres es para verificar :func:`isinstance` o :func:" +"`issubclass`." #: ../Doc/library/types.rst:102 msgid "" "If you instantiate any of these types, note that signatures may vary between " "Python versions." msgstr "" +"Si se crea una instancia de cualquiera de estos tipos, tenga en cuenta que " +"las firmas pueden variar entre las versiones de Python." #: ../Doc/library/types.rst:104 msgid "Standard names are defined for the following types:" -msgstr "" +msgstr "Los nombres estándar son definidos para los siguientes tipos:" #: ../Doc/library/types.rst:109 msgid "" "The type of user-defined functions and functions created by :keyword:" "`lambda` expressions." msgstr "" +"El tipo de funciones definidas por el usuario y funciones creadas por " +"expresiones :keyword:`lambda`." #: ../Doc/library/types.rst:115 msgid "" "The type of :term:`generator`-iterator objects, created by generator " "functions." msgstr "" +"El tipo de iterador :term:`generator` de objetos, creados por funciones " +"generadoras." #: ../Doc/library/types.rst:121 msgid "" "The type of :term:`coroutine` objects, created by :keyword:`async def` " "functions." msgstr "" +"El tipo de objetos :term:`coroutine`, creados por funciones :keyword:`async " +"def`." #: ../Doc/library/types.rst:129 msgid "" "The type of :term:`asynchronous generator`-iterator objects, created by " "asynchronous generator functions." msgstr "" +"El tipo de iterador :term:`asynchronous generator` de objetos, creados por " +"funciones generadoras asíncronas." #: ../Doc/library/types.rst:139 msgid "The type for code objects such as returned by :func:`compile`." -msgstr "" +msgstr "El tipo de objetos de código cómo los retornados por :func:`compile`." #: ../Doc/library/types.rst:142 msgid "" @@ -196,27 +251,37 @@ msgid "" "``code``, ``filename``, ``name``, ``argcount``, ``posonlyargcount``, " "``kwonlyargcount``, ``nlocals``, ``stacksize``, ``flags``." msgstr "" +"Lanza un :ref:`evento auditor ` ``code.__new__`` con los " +"argumentos ``code``, ``filename``, ``name``, ``argcount``, " +"``posonlyargcount``, ``kwonlyargcount``, ``nlocals``, ``stacksize``, " +"``flags``." #: ../Doc/library/types.rst:143 msgid "" "Note that the audited arguments may not match the names or positions " "required by the initializer." msgstr "" +"Tenga en cuenta que los argumentos auditados pueden no coincidir con los " +"nombres o posiciones requeridos por el inicializador." #: ../Doc/library/types.rst:148 msgid "" "Return a copy of the code object with new values for the specified fields." msgstr "" +"Retorna una copia del objeto de código con nuevos valores para los campos " +"especificados." #: ../Doc/library/types.rst:154 msgid "" "The type for cell objects: such objects are used as containers for a " "function's free variables." msgstr "" +"El tipo de objetos de celda: estos objetos se utilizan como contenedores " +"para las variables libres de una función." #: ../Doc/library/types.rst:162 msgid "The type of methods of user-defined class instances." -msgstr "" +msgstr "El tipo de métodos de instancias de clase definidas por el usuario." #: ../Doc/library/types.rst:168 msgid "" @@ -224,57 +289,74 @@ msgid "" "methods of built-in classes. (Here, the term \"built-in\" means \"written " "in C\".)" msgstr "" +"El tipo de funciones integradas como :func:`len` o :func:`sys.exit` y " +"métodos de clases integradas. (Aquí, el término \"incorporado\" significa " +"\"escrito en C\".)" #: ../Doc/library/types.rst:175 msgid "" "The type of methods of some built-in data types and base classes such as :" "meth:`object.__init__` or :meth:`object.__lt__`." msgstr "" +"El tipo de métodos de algunos tipos de datos integrados y clases base como :" +"meth:`object.__init__` o :meth:`object.__lt__`." #: ../Doc/library/types.rst:183 msgid "" "The type of *bound* methods of some built-in data types and base classes. " "For example it is the type of :code:`object().__str__`." msgstr "" +"El tipo de métodos *bound* de algunos tipos de datos integrados y clases " +"base. Por ejemplo, es el tipo de :code:`object().__str__`." #: ../Doc/library/types.rst:191 msgid "" "The type of methods of some built-in data types such as :meth:`str.join`." msgstr "" +"El tipo de métodos de algunos tipos de datos integrados como :meth:`str." +"join`." #: ../Doc/library/types.rst:198 msgid "" "The type of *unbound* class methods of some built-in data types such as " "``dict.__dict__['fromkeys']``." msgstr "" +"El tipo de métodos de clase *unbound* de algunos tipos de datos integrados " +"como ``dict.__dict__['fromkeys']``." #: ../Doc/library/types.rst:206 msgid "" "The type of :term:`modules `. Constructor takes the name of the " "module to be created and optionally its :term:`docstring`." msgstr "" +"El tipo de :term:`módulos `. El constructor toma el nombre del " +"módulo que se va a crear y de forma opcional su :term:`docstring`." #: ../Doc/library/types.rst:210 msgid "" "Use :func:`importlib.util.module_from_spec` to create a new module if you " "wish to set the various import-controlled attributes." msgstr "" +"Utilice :func:`importlib.util.module_from_spec` para crear un nuevo módulo " +"si desea establecer los diversos atributos controlados por importación." #: ../Doc/library/types.rst:215 msgid "The :term:`docstring` of the module. Defaults to ``None``." -msgstr "" +msgstr "El :term:`docstring` del módulo. El valor predeterminado es ``None``." #: ../Doc/library/types.rst:219 msgid "The :term:`loader` which loaded the module. Defaults to ``None``." msgstr "" +"El :term:`loader` que cargó el módulo. El valor predeterminado es ``None``." #: ../Doc/library/types.rst:221 ../Doc/library/types.rst:235 msgid "Defaults to ``None``. Previously the attribute was optional." msgstr "" +"El valor predeterminado es ``None``. Anteriormente el atributo era opcional." #: ../Doc/library/types.rst:226 msgid "The name of the module." -msgstr "" +msgstr "El nombre del módulo." #: ../Doc/library/types.rst:230 msgid "" @@ -283,10 +365,17 @@ msgid "" "``''``, else it should be set to the name of the package (which can be :attr:" "`__name__` if the module is a package itself). Defaults to ``None``." msgstr "" +"A cuál :term:`package` pertenece un módulo. Si el módulo es de nivel " +"superior (es decir, no una parte de algún paquete específico), el atributo " +"debe establecerse en ``''``, de lo contrario debe establecerse en el nombre " +"del paquete (el cual puede ser :attr:`__name__` si el módulo es un paquete). " +"El valor predeterminado es ``None``." #: ../Doc/library/types.rst:241 msgid "The type of traceback objects such as found in ``sys.exc_info()[2]``." msgstr "" +"El tipo de objetos *traceback* tal como los encontrados en ``sys.exc_info()" +"[2]``." #: ../Doc/library/types.rst:243 msgid "" @@ -294,18 +383,25 @@ msgid "" "available attributes and operations, and guidance on creating tracebacks " "dynamically." msgstr "" +"Consulte :ref:`la referencia de lenguaje ` para obtener " +"detalles de los atributos y operaciones disponibles, y orientación sobre " +"cómo crear *tracebacks* dinámicamente." #: ../Doc/library/types.rst:250 msgid "" "The type of frame objects such as found in ``tb.tb_frame`` if ``tb`` is a " "traceback object." msgstr "" +"El tipo de objetos de marco como se encuentra en ``tb.tb_frame`` si ``tb`` " +"es un objeto *traceback*." #: ../Doc/library/types.rst:253 msgid "" "See :ref:`the language reference ` for details of the " "available attributes and operations." msgstr "" +"Consulte :ref:`la referencia de lenguaje ` para obtener más " +"información sobre los atributos y operaciones disponibles." #: ../Doc/library/types.rst:259 msgid "" @@ -314,6 +410,11 @@ msgid "" "descriptor for object attributes; it has the same purpose as the :class:" "`property` type, but for classes defined in extension modules." msgstr "" +"El tipo de objetos definidos en módulos de extensión con ``PyGetSetDef``, " +"como ``FrameType.f_locals`` o ``array.array.typecode``. Este tipo se " +"utiliza como descriptor para los atributos de objeto; tiene el mismo " +"propósito que el tipo :class:`property`, pero para las clases definidas en " +"los módulos de extensión." #: ../Doc/library/types.rst:267 msgid "" @@ -323,12 +424,19 @@ msgid "" "purpose as the :class:`property` type, but for classes defined in extension " "modules." msgstr "" +"El tipo de objetos definidos en módulos de extensión con ``PyMemberDef``, " +"como ``datetime.timedelta.days``. Este tipo se utiliza como descriptor para " +"miembros de datos C simples que utilizan funciones de conversión estándar; " +"tiene el mismo propósito que el tipo :class:`property`, pero para las clases " +"definidas en los módulos de extensión." #: ../Doc/library/types.rst:274 msgid "" "In other implementations of Python, this type may be identical to " "``GetSetDescriptorType``." msgstr "" +"En otras implementaciones de Python, este tipo puede ser idéntico a " +"``GetSetDescriptorType``." #: ../Doc/library/types.rst:279 msgid "" @@ -336,31 +444,40 @@ msgid "" "entries, which means that when the mapping changes, the view reflects these " "changes." msgstr "" +"Proxy de solo lectura de un mapeo. Proporciona una vista dinámica en las " +"entradas de la asignación, lo que significa que cuando cambia la asignación, " +"la vista refleja estos cambios." #: ../Doc/library/types.rst:287 msgid "" "Return ``True`` if the underlying mapping has a key *key*, else ``False``." msgstr "" +"Retorna ``True`` si la asignación subyacente tiene una clave *key*, de lo " +"contrario ``False``." #: ../Doc/library/types.rst:292 msgid "" "Return the item of the underlying mapping with key *key*. Raises a :exc:" "`KeyError` if *key* is not in the underlying mapping." msgstr "" +"Retorna el elemento de la asignación subyacente con la clave *key*. Lanza " +"un :exc:`KeyError` si *key* no está en la asignación subyacente." #: ../Doc/library/types.rst:297 msgid "" "Return an iterator over the keys of the underlying mapping. This is a " "shortcut for ``iter(proxy.keys())``." msgstr "" +"Retorna un iterador sobre las claves de la asignación subyacente. Este es " +"un método abreviado para ``iter(proxy.keys())``." #: ../Doc/library/types.rst:302 msgid "Return the number of items in the underlying mapping." -msgstr "" +msgstr "Retorna el número de elementos de la asignación subyacente." #: ../Doc/library/types.rst:306 msgid "Return a shallow copy of the underlying mapping." -msgstr "" +msgstr "Retorna una copia superficial de la asignación subyacente." #: ../Doc/library/types.rst:310 msgid "" @@ -368,29 +485,37 @@ msgid "" "*default*. If *default* is not given, it defaults to ``None``, so that this " "method never raises a :exc:`KeyError`." msgstr "" +"Retorna el valor de *key* si *key* está en la asignación subyacente, de lo " +"contrario *default*. Si no se proporciona *default*, el valor " +"predeterminado es ``None``, por lo que este método nunca lanza un :exc:" +"`KeyError`." #: ../Doc/library/types.rst:316 msgid "" "Return a new view of the underlying mapping's items (``(key, value)`` pairs)." msgstr "" +"Retorna una nueva vista de los elementos de la asignación subyacente (en " +"pares ``(key, value)``)." #: ../Doc/library/types.rst:321 msgid "Return a new view of the underlying mapping's keys." -msgstr "" +msgstr "Retorna una nueva vista de las claves de la asignación subyacente." #: ../Doc/library/types.rst:325 msgid "Return a new view of the underlying mapping's values." -msgstr "" +msgstr "Retorna una nueva vista de los valores de la asignación subyacente." #: ../Doc/library/types.rst:329 msgid "Additional Utility Classes and Functions" -msgstr "" +msgstr "Clases y funciones de utilidad adicionales" #: ../Doc/library/types.rst:333 msgid "" "A simple :class:`object` subclass that provides attribute access to its " "namespace, as well as a meaningful repr." msgstr "" +"Una subclase simple :class:`object` que proporciona acceso de atributo a su " +"espacio de nombre, así como una representación significativa." #: ../Doc/library/types.rst:336 msgid "" @@ -398,10 +523,14 @@ msgid "" "attributes. If a ``SimpleNamespace`` object is initialized with keyword " "arguments, those are directly added to the underlying namespace." msgstr "" +"A diferencia de :class:`object`, con ``SimpleNamespace`` puede agregar y " +"eliminar atributos. Si un objeto ``SimpleNamespace`` se inicializa con " +"argumentos de palabra clave, estos se agregan directamente al espacio de " +"nombres subyacente." #: ../Doc/library/types.rst:340 msgid "The type is roughly equivalent to the following code::" -msgstr "" +msgstr "El tipo es aproximadamente equivalente al código siguiente::" #: ../Doc/library/types.rst:354 msgid "" @@ -409,10 +538,13 @@ msgid "" "However, for a structured record type use :func:`~collections.namedtuple` " "instead." msgstr "" +"``SimpleNamespace`` puede ser útil como reemplazo para ``class NS: pass``. " +"Sin embargo, para un tipo de registro estructurado, utilice :func:" +"`~collections.namedtuple` en su lugar." #: ../Doc/library/types.rst:363 msgid "Route attribute access on a class to __getattr__." -msgstr "" +msgstr "Acceso de atributo de ruta en una clase para __getattr__." #: ../Doc/library/types.rst:365 msgid "" @@ -421,16 +553,24 @@ msgid "" "normal, but access to an attribute through a class will be routed to the " "class's __getattr__ method; this is done by raising AttributeError." msgstr "" +"Se trata de un descriptor, que se utiliza para definir atributos que actúan " +"de forma diferente cuando se accede a través de una instancia y a través de " +"una clase. El acceso a la instancia sigue siendo normal, pero el acceso a " +"un atributo a través de una clase se enrutará al método __getattr__ de la " +"clase; esto se hace lanzando AttributeError." #: ../Doc/library/types.rst:370 msgid "" "This allows one to have properties active on an instance, and have virtual " "attributes on the class with the same name (see Enum for an example)." msgstr "" +"Esto permite tener propiedades activas en una instancia y tener atributos " +"virtuales en la clase con el mismo nombre (consulte Enum para obtener un " +"ejemplo)." #: ../Doc/library/types.rst:377 msgid "Coroutine Utility Functions" -msgstr "" +msgstr "Funciones de utilidad de corutina" #: ../Doc/library/types.rst:381 msgid "" @@ -440,10 +580,15 @@ msgid "" "considered to be a :term:`coroutine` object and is :term:`awaitable`. " "However, it may not necessarily implement the :meth:`__await__` method." msgstr "" +"Esta función transforma una función :term:`generador` en una función :term:" +"`coroutine` que retorna una corrutina basada en un generador. La corrutina " +"basada en un generador sigue siendo un :term:`generator iterator`, pero " +"también se considera un objeto :term:`coroutine` y es :term:`awaitable`. " +"Sin embargo, no puede necesariamente implementar el método :meth:`__await__`." #: ../Doc/library/types.rst:388 msgid "If *gen_func* is a generator function, it will be modified in-place." -msgstr "" +msgstr "Si *gen_func* es una función generadora, se modificará en el lugar." #: ../Doc/library/types.rst:390 msgid "" @@ -452,3 +597,7 @@ msgid "" "wrapped in an *awaitable* proxy object. All other types of objects will be " "returned as is." msgstr "" +"Si *gen_func* no es una función generadora, se envolverá. Si retorna una " +"instancia de :class:`collections.abc.Generator`, la instancia se ajustará en " +"un objeto proxy *awaitable*. Todos los demás tipos de objetos se retornarán " +"tal cual."