Fetches all configured IPsecSiteConnections for a project.
558358
def list_ipsec_site_connections(self, retrieve_all=True, **_params):
        """"""
        return self.list('ipsec_site_connections',
                         self.ipsec_site_connections_path,
                         retrieve_all,
                         **_params)
386483
public java.util.List<VpcPeeringConnection> getVpcPeeringConnections() {
        if (vpcPeeringConnections == null) {
            vpcPeeringConnections = new com.amazonaws.internal.SdkInternalList<VpcPeeringConnection>();
        }
        return vpcPeeringConnections;
    }
819467
def iterconnections(self):
        
        return itertools.chain(
            self.secureConnectionCache.cachedConnections.itervalues(),
            iter(self.subConnections),
            (self.dispatcher or ()) and self.dispatcher.iterconnections())
157120
def open_connections(self):
        """"""
        return [(host, len(li)) for (host, li) in self._cm.get_all().items()]
260554
def get_connections(self, id, connection_name, **args):
        """"""
        return self.request(
            "{0}/{1}/{2}".format(self.version, id, connection_name), args
        )
215596
public Set<Integer> getConnections(String endpointId) {
        return Collections.unmodifiableSet(this.entries.get(endpointId));
    }
1345878
private static List<ConnectionNotation> getAllSelfCycleConnections(List<ConnectionNotation> connections) {
    List<ConnectionNotation> listSelfCycle = new ArrayList<ConnectionNotation>();
    for (ConnectionNotation connection : connections) {
      if ((connection.getTargetId().getId().equals(connection.getSourceId().getId()))) {
        listSelfCycle.add(connection);
      }
    }
    return listSelfCycle;
  }
750945
def connections(self):
        
        conn = lambda x: str(x).replace('connection:', '')
        return [conn(name) for name in self.sections()]
184599
def _list_collections(self, sock_info, slave_okay, session,
                          read_preference, **kwargs):
        """"""

        coll = self.get_collection(
            "$cmd", read_preference=read_preference)
        if sock_info.max_wire_version > 2:
            cmd = SON([("listCollections", 1),
                       ("cursor", {})])
            cmd.update(kwargs)
            with self.__client._tmp_session(
                    session, close=False) as tmp_session:
                cursor = self._command(
                    sock_info, cmd, slave_okay,
                    read_preference=read_preference,
                    session=tmp_session)["cursor"]
                return CommandCursor(
                    coll,
                    cursor,
                    sock_info.address,
                    session=tmp_session,
                    explicit_session=session is not None)
        else:
            match = _INDEX_REGEX
            if "filter" in kwargs:
                match = {"$and": [_INDEX_REGEX, kwargs["filter"]]}
            dblen = len(self.name.encode("utf8") + b".")
            pipeline = [
                {"$project": {"name": {"$substr": ["$name", dblen, -1]},
                              "options": 1}},
                {"$match": match}
            ]
            cmd = SON([("aggregate", "system.namespaces"),
                       ("pipeline", pipeline),
                       ("cursor", kwargs.get("cursor", {}))])
            cursor = self._command(sock_info, cmd, slave_okay)["cursor"]
            return CommandCursor(coll, cursor, sock_info.address)
997268
private HttpConnectorList getHttpConnectors() throws Exception {
        logger.info("Searching HTTP connectors.");
        HttpConnectorList httpConnectorList = null;
        //find Jboss first as is typical setup
        httpConnectorList = jBossConnectorDiscover.findConnectors();
        if (httpConnectorList == null || httpConnectorList.getConnectors().isEmpty()) {
            //if not found try tomcat
            httpConnectorList = new TomcatConnectorDiscover().findConnectors();
        }
        return httpConnectorList;
    }
1321966
def get_all_switch_ips(self):
        """"""

        switch_connections = []
        try:
            bindings = nxos_db.get_reserved_switch_binding()
        except excep.NexusPortBindingNotFound:
            LOG.error("No switch bindings in the port data base")
            bindings = []
        for switch in bindings:
            switch_connections.append(switch.switch_ip)

        return switch_connections
969683
def _get_ips(networks):
    '''
    
    '''
    v4s = networks.get('v4')
    v6s = networks.get('v6')
    public_ips = []
    private_ips = []

    if v4s:
        for item in v4s:
            ip_type = item.get('type')
            ip_address = item.get('ip_address')
            if ip_type == 'public':
                public_ips.append(ip_address)
            if ip_type == 'private':
                private_ips.append(ip_address)

    if v6s:
        for item in v6s:
            ip_type = item.get('type')
            ip_address = item.get('ip_address')
            if ip_type == 'public':
                public_ips.append(ip_address)
            if ip_type == 'private':
                private_ips.append(ip_address)

    return public_ips, private_ips
426612
function getNetworkInterfaces() {
    const ret = {};
    for (const macinfo of Object.values(macs)) {
        if (!macinfo.self) {
            continue;
        }
        ret[macinfo.net] = objCpy(macinfo);
    }
    return ret;
}
69889
def get_ntp_servers(self):
        """"""
        ntp_table = junos_views.junos_ntp_servers_config_table(self.device)
        ntp_table.get()

        ntp_servers = ntp_table.items()

        if not ntp_servers:
            return {}

        return {napalm_base.helpers.ip(server[0]): {} for server in ntp_servers}
678147
def list_ipsecpolicies(self, retrieve_all=True, **_params):
        """"""
        return self.list('ipsecpolicies',
                         self.ipsecpolicies_path,
                         retrieve_all,
                         **_params)
1169158
def GetIPAddresses(self):
    """"""
    result = []
    filtered_ips = ["127.0.0.1", "::1", "fe80::1"]

    for interface in self.interfaces:
      for address in interface.addresses:
        if address.human_readable_address not in filtered_ips:
          result.append(Text(address.human_readable_address))
    return sorted(result)
179285
def get_projects():
    
    conn, c = open_data_base_connection()
    try:
        c.execute("""SELECT project_name FROM main_table""")
        project_names = np.array(c.fetchall()).squeeze(axis=1)
        project_names = convert_list_to_dict(project_names)
        return project_names
    except sqlite3.OperationalError:
        logging.info("{} not found".format(run_name))
    finally:
        conn.close()