Iterator An iterator is an object that contains a countable number of values and consists of the methods __iter__ and __next__. __iter__: This method is called...
Continue reading...It is all about technology Learn Something New Everyday
Python: Magic Methods, Context Manager
Magic methods __new__: Called to create a new instance of class cls. What is happening at the moment of class creation (like checking if there should...
Continue reading...Python: Files, Exceptions, and Errors
Files Opening files using the with statement is recommended because it ensures that the file is automatically closed at the ends of the with the statement....
Continue reading...Python: Class Inheritance and Compositions
Inheritance A Derived class inherits from a Base class and is a specialized version of Base. It allows defining a class that inherits all the methods...
Continue reading...WebApp: Cisco ISE-Python-Flask
My previous post “Python and ISE Monitor Mode” was about how to collect access-session information from the switch and use it for endpoint verification. Specifically for...
Continue reading...Python and ISE Monitor Mode
There are several ways to run ISE (wired) in monitor mode and AuthZ results: dACL, another VLAN, etc. It is always a good idea 🙂 to...
Continue reading...Python: Classes and Methods
Everything is a object in Python. the simplest class in Python: Class and Instance Attributes Class attributes are attributes that are owned by the class itself. ...
Continue reading...Python: Dictionaries and JSON
Dictionaries Dictionary – a collection of keys and values, unordered, changeable and indexed. Dictionary comprehensions Creating a dictionary from the list of keys with default value:...
Continue reading...Python: Apply config to multiple interfaces (with the condition)
It is not about range feature:) After my post about how to get into the switch with “not sure” credentials, let’s assume you fixed access and...
Continue reading...Python More About Lists
List Comprehensions One way to create a list with for loop: List comprehensions are an elegant way to build a list without having to use another...
Continue reading...