- Sobre o que se trata OOP
- Reuso (objeto pode ser reaproveitado por outros contextos)
- Abstração
- Encapsulamento (esconder implementação)
- Alta Coesão (objeto fazer bem uma única coisa)
- Baixo Acoplamento (objeto pode ser substituído sem afetar outros objetos)
- Elementos OOP
- Interface
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| neumann johnathafelix/main ~/Work/experiments/node-chromedriver | |
$ npm install | |
> [email protected] install | |
> node install.js | |
Current existing ChromeDriver binary is unavailable, proceeding with download and extraction. | |
Downloading from file: https://chromedriver.storage.googleapis.com/93.0.4577.15/chromedriver_mac64_m1.zip | |
Saving to file: /var/folders/68/xm9lt4hn05g87sh09p2ycb500000gn/T/93.0.4577.15/chromedriver/chromedriver_mac64_m1.zip | |
Received 1040K... |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import re | |
rawwords = { | |
"whitelist": "gbvampnkwxxbgxgxbgxkxbgxfwnkvaatuxgwbxlxdxbgxptkxgatmmxbffxklvahgngmxkzxzxgebxzmlmxamcxmsmlxbxgwbxlxdhffmxbgxlwtuxbwtfbmlxbgxcxmsmgxnxglmtmmctakxaxnmxlmtwmpxkwxxklmxxmptlsnwxfexuxgbagxgobxexwtuxbftvamzxuxgubmmxaxnmxpxzxglibxelbxamobxexlxaxglxbmxlxbgxbakxguxbwxzxaxgxbgxglhztketgzxwnkvalmbxzsxbzmwtmxglmtgwyktzxkheexmaxftteexlzkngwwtfbmikxblbakxgztgsxltzmxzxzxgteexguebxubakxkgbffmlmtkutuxgwyhezxietmsmbmxetikbewknvdlmtkdabeyxphvaxyxaemlxmsmlheexfnlbdubmmxzxkgxlxvalsnwxftdmbxdtfxggxnxkuebvdgtfxgteexfwkhamdxbgxftkdmcxwxkfxbgxptknfwtohgyhezmpxgbzhiyxkltvaxyhmhlkxzxenglxkzxgtncxwxggxnxltnzxgwtaxkbffxkebxuxfbmmxingdmlvahgngmxkcxwxkfxbgxkxvamlmttmtemxgexuxgfxblmteexlexnmxfxmxkmtzxguxlmxznmxgabeymbakxfhyyxgltzxgytakmeblmxmbxkxngbhgwtaxkbagxgpbkdmdkblxftvamgtmnkkxblxlbvamlhglmuxbwxdgtiigxuxgkxbaxlnvaxxgwxmahaxgnglxktemxkdkbxzgtvamlmtgwpxzxgznmxkcngzxexzmxlhkzmuxknyuhwxgwbgzxyxnxkdktymebvamlihkmztuxgabgsnmkbmmutlblbwxxgdtfiygbvamkngwxwbxgmdxggmexlxglbmsmlmx |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# : | |
# : | |
youplanny/poetry.lock: pyproject.toml | |
poetry lock | |
requirements.txt: poetry.lock | |
poetry export --without-hashes -f requirements.txt -o requirements.txt | |
deploy: requirements.txt |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def say(animal_name): | |
match animal_name: | |
case 'cow': | |
print('mu!') | |
case 'duck': | |
print('quack!') | |
case _: | |
print(f'Invalid animal type: {animal_name}') |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- resource: listing | |
- permissions: | |
- profile1: | |
- READ | |
- profile2: | |
- UPDATE | |
- fields: | |
- code: | |
- profile1: | |
- SET |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$ dig aduniverso.com.br | |
; <<>> DiG 9.10.6 <<>> aduniverso.com.br | |
;; global options: +cmd | |
;; Got answer: | |
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 2534 | |
;; flags: qr rd ra; QUERY: 1, ANSWER: 1, AUTHORITY: 4, ADDITIONAL: 5 | |
;; OPT PSEUDOSECTION: | |
; EDNS: version: 0, flags:; udp: 4096 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/Lib/os.py b/Lib/os.py | |
index e293ecae7f..4dfa41c712 100644 | |
--- a/Lib/os.py | |
+++ b/Lib/os.py | |
@@ -25,6 +25,7 @@ and opendir), and leave all pathname manipulation to os.path | |
import abc | |
import sys, errno | |
import stat as st | |
+import _thread | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import re | |
import wikipedia | |
def parse(raw_content): | |
section_title_re = re.compile("^=+\s+.*\s+=+$") | |
content = [] | |
skip = False | |
for l in raw_content.splitlines(): | |
line = l.strip() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Error(Exception): | |
pass | |
class RecoverableError(Error): | |
pass | |
class NonRecoverableError(Error): |