TGTGInsightтелеграм анализLIVE / telegram public index
← Такты, стеки, два колеса

TGINSIGHT SIMILAR POSTS

Намери подобно съдържание

Изходен канал @clockstackwheels · Post #296 · 11.04

Паттерн Декоратор — специальный способ организации модулей в программе, который позволяет подставить какую-то новую функцию прямо в середину цепочки вызовов, тем самым чуть-чуть подкорректировав поведение. Например, в реальном мире очки для чтения это декоратор. Вы ставите их между вашими глазами и текстом. Глобально взаимодействие ваших глаз и текста не меняется: отражённые световые лучи от страницы книги попадают в ваши зрачки, что с очками, что без них. Но очки располагаются посередине: они принимают лучи на вход и преломляют их, передавая дальше вам в глаза уже изменёнными. Важной особенностью является тот факт, что очки можно снять. Они не требуют ни модификации вашего тела, ни модификации книги. Вообще никакие условия не нужны, кроме наличия самих очков. А если вы в линзах, то внешний наблюдатель может даже этого не знать. Класс-декоратор должен быть спроектирован так, чтобы не требовать никаких изменений в объектах, с которыми он работает. Его можно отключить, чаще всего буквально закомментировав одну строку. В примере ниже программа выведет текст "Привет, мир, в натуре.", и вот это дополнение в конце как раз дописано декоратором. Можно убрать или закомментировать подчёркнутую строчку, не трогая остальной код, для всех внешних вызовов сигнатуры останутся теми же самыми, но выводиться будет уже просто "Привет, мир". В декораторы можно прятать логику, которую буквально навешивают поверх основной функции программы. Например, проверку прав на выполнение операции. Перевод на другой язык, логирование, поддержку обратной совместимости при обновлении и так далее. #dev

Hashtags

Резултати

Намерени 29 подобни публикации

Търсене: #solar

当前筛选 #solar清除筛选
Indian Development News 🇮🇳

@developmentnewsindia · Post #44371 · 03.05.2026 г., 13:50

Tata Power Renewable Energy Limited (TPREL) received board approval to invest ₹6,500 crore to establish a 10 GW photovoltaic ingot and wafer manufacturing facility. The project will be developed in two phases of 5 GW each, likely at a greenfield site in Nellore, Andhra Pradesh, with an estimated payback period of five years. This strategic expansion into upstream manufacturing allows Tata Power to achieve backward integration, significantly reducing reliance on Chinese imports while aligning with India’s ALMM framework to strengthen the domestic solar supply chain. Source #MakeInindia#solar

Indian Development News 🇮🇳

@developmentnewsindia · Post #44370 · 03.05.2026 г., 13:40

Andhra Pradesh Chief Minister N Chandrababu Naidu will lay the foundation stone for ReNew Energy Global plc's Rs 5,400 crore solar manufacturing facility in Anakapalli district. This 6 GW solar ingot and wafer unit marks a significant step in India's push for domestic clean energy manufacturing and energy security, aligning with the state's Integrated Clean Energy Policy 2024 Source #MakeInindia#solar

Interesting Planet 🌍

@interesting_planet_facts · Post #864 · 05.10.2025 г., 20:11

🌎 Pluto, once called the ninth planet, orbits in the distant Kuiper Belt and takes about 248 Earth years to complete one orbit around the Sun. ✨ #planets⚡#astronomy⚡#solar-system 👉subscribe Interesting Planet 👉more Channels ​

Interesting Planet 🌍

@interesting_planet_facts · Post #664 · 31.08.2025 г., 18:22

🌎 Jupiter’s Great Red Spot is a giant storm larger than Earth and has been raging for at least 350 years, swirling powerful winds nonstop across the planet’s atmosphere. ✨ #planets⚡#astronomy⚡#solar 👉subscribe Interesting Planet ​

Amazing Geography 🌍

@amazingeo · Post #205 · 09.09.2025 г., 13:12

🌍 On rare occasions, the aurora can be seen far from the poles, reaching as far south as Texas or southern Europe during strong solar storms. Their shifting shapes can move faster than a cheetah runs. ✨ #aurora⚡#atmosphere⚡#solar⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography🌍 ​

Amazing Geography 🌍

@amazingeo · Post #222 · 12.09.2025 г., 09:12

🌍 Earth travels around the Sun at nearly 30 kilometers per second. This speedy journey means our planet covers more than 940 million kilometers every year as it orbits through space. ✨ #Earth⚡#orbit⚡#solar⚡#geography⚡#nature⚡#earth 👉subscribe Amazing Geography🌍 ​

Universe Mysteries 🪐

@cosmomyst · Post #721 · 24.03.2026 г., 22:21

🪐 NASA and ESA are collaborating on future missions to develop solar sail technology—a method that harnesses sunlight for propulsion—to power lightweight spacecraft toward nearby stars like Alpha Centauri. Unlike rockets, solar sails use the gentle push of photons (tiny particles of light) from the Sun to gradually accelerate, making it possible for small probes to reach interstellar space without carrying any fuel onboard. ✨ #spaceships⚡#interstellar⚡#solar⚡#nasa⚡#galaxy⚡#stars⚡#astronomy⚡#universe⚡#cosmos⚡#space 👉subscribe Universe Mysteries 👉more Channels ​

ПредишнаСтр. 1 от 3Следваща