Python

TypedDict

Në shqip përdoret i njëjti emër.

ShpjegimiSQ

TypedDict përshkruan formën e një fjalori — cilat çelësa ka dhe çfarë tipi janë vlerat — që editori të të paralajmërojë kur gabon një çelës. Shumë i dobishëm për të dhëna JSON.

EnglishEN

TypedDict describes the shape of a dictionary — which keys it has and what type the values are — so the editor warns you when you mistype a key. Very useful for JSON data.

Si ta mendosh

Si formulari me kuti të shënuara.

Lexoje në anglisht

Like a form with labelled boxes.

Shembull kodipython

from typing import TypedDict
class Termi(TypedDict):
    id: str
    emri: str

Terma të lidhur