Get all topicrefs
335433
private List<Element> getTopicrefs(final Element root) {
        final List<Element> res = new ArrayList<>();
        final NodeList all = root.getElementsByTagName("*");
        for (int i = 0; i < all.getLength(); i++) {
            final Element elem = (Element) all.item(i);
            if (MAP_TOPICREF.matches(elem)
                    && isDitaFormat(elem.getAttributeNode(ATTRIBUTE_NAME_FORMAT))
                    && !elem.getAttribute(ATTRIBUTE_NAME_SCOPE).equals(ATTR_SCOPE_VALUE_EXTERNAL)) {
                res.add(elem);
            }
        }
        return res;
    }
1151708
def all(self, res):
        ""
        B = get_backend()
        return B.get_objects(B.get_concrete(res))
223130
public static Topic asRef( Topic topic ) throws JMSException
    {
        if (topic == null)
            return null;
            
        if (topic instanceof TopicRef)
            return topic;
        
        return new TopicRef(topic.getTopicName());
    }
189537
public Topic getTopic(String topicName) throws ServiceLocatorException {
		Topic topic = null;
		try {
			topic = (Topic) ic.lookup(topicName);
		} catch (NamingException ne) {
			throw new ServiceLocatorException(ne);
		} catch (Exception e) {
			throw new ServiceLocatorException(e);
		}
		return topic;
	}
188722
def list_topics(self, Nwords=10):
        
        return [(k, self.list_topic(k, Nwords)) for k in xrange(len(self.phi))]
1195015
public function getTopics()
    {
        $topic = BaseManager::build('FelixOnline\Core\ArticleTopic', 'article_topic', 'topic')
            ->filter('article = %i', array($this->getId()));

        $topics = BaseManager::build('FelixOnline\Core\Topic', 'topic', 'slug')
            ->join($topic, 'LEFT', 'slug', 'topic')
            ->filter('disabled = 0')
            ->values();

        return $topics;
    }
110041
List<FilterUtils> combineFilterUtils(final Element topicref, final List<FilterUtils> filters,
                                         final SubjectScheme subjectSchemeMap) {
        return getChildElement(topicref, DITAVAREF_D_DITAVALREF)
                .map(ditavalRef -> getFilterUtils(ditavalRef).refine(subjectSchemeMap))
                .map(f -> {
                    final List<FilterUtils> fs = new ArrayList<>(filters.size() + 1);
                    fs.addAll(filters);
                    fs.add(f);
                    return fs;
                })
                .orElse(filters);
    }
1309736
def get_all(self, name, default=None):
        """"""
        if default is None:
            default = []
        return self._headers.get_list(name) or default
1020823
def topics(options = {})
      batches = Enumerator.new do |y|
        resp = @client.list_topics(options)
        resp.each_page do |page|
          batch = []
          page.data.topics.each do |t|
            batch << Topic.new(
              arn: t.topic_arn,
              client: @client
            )
          end
          y.yield(batch)
        end
      end
      Topic::Collection.new(batches)
    end
1161119
def get_topic_attributes(TopicArn, region=None, key=None, keyid=None, profile=None):
    '''
    
    '''
    conn = _get_conn(region=region, key=key, keyid=keyid, profile=profile)
    try:
        return conn.get_topic_attributes(TopicArn=TopicArn).get('Attributes')
    except botocore.exceptions.ClientError as e:
        log.error('Failed to garner attributes for SNS topic %s: %s', TopicArn, e)
        return None
246655
def extract(self, topic: str, parseNumbers=True) -> list:
        
        cls = type(topic, (DynamicObject,), {})
        results = [cls(**node.attrib) for node in self.root.iter(topic)]
        if parseNumbers:
            for obj in results:
                d = obj.__dict__
                for k, v in d.items():
                    with suppress(ValueError):
                        d[k] = float(v)
                        d[k] = int(v)
        return results
454809
function getAllReferences() {
  return _.reduce(
    this.getInheritanceChain(),
    (acc, cls) => _.reduce(cls.references, (acc2, v, k) => {acc2[k] = v; return acc2}, acc),
    {})
}
1087353
def followed_topics(self):
        
        from .topic import Topic
        if self.url is None:
            return
        if self.followed_topic_num > 0:
            tag = self.soup.find('div', class_='zm-profile-side-topics')
            if tag is not None:
                for a in tag.find_all('a'):
                    yield Topic(Zhihu_URL + a['href'], a.img['alt'],
                                session=self._session)
            if self.followed_topic_num > 7:
                offset = 7
                gotten_data_num = 20
                while gotten_data_num == 20:
                    data = {'start': 0, 'offset': offset, '_xsrf': self.xsrf}
                    j = self._session.post(
                        Author_Get_More_Follow_Topic_URL.format(self.id),
                        data=data).json()
                    gotten_data_num = j['msg'][0]
                    offset += gotten_data_num
                    topic_item = BeautifulSoup(j['msg'][1]).find_all(
                        'div', class_='zm-profile-section-item')
                    for div in topic_item:
                        name = div.strong.text
                        url = Zhihu_URL + div.a['href']
                        yield Topic(url, name, session=self._session)
53126
def getrefnames(idf, objname):
    """"""
    iddinfo = idf.idd_info
    dtls = idf.model.dtls
    index = dtls.index(objname)
    fieldidds = iddinfo[index]
    for fieldidd in fieldidds:
        if 'field' in fieldidd:
            if fieldidd['field'][0].endswith('Name'):
                if 'reference' in fieldidd:
                    return fieldidd['reference']
                else:
                    return []
1228959
public String getTopicIds() {
    if (Token_Type.featOkTst && ((Token_Type)jcasType).casFeat_topicIds == null)
      jcasType.jcas.throwFeatMissing("topicIds", "de.julielab.jules.types.Token");
    return jcasType.ll_cas.ll_getStringValue(addr, ((Token_Type)jcasType).casFeatCode_topicIds);}
279124
def get_all(self, search_filter=None):
        """"""
        items = self.backend.get_all()

        if not items:
            if self.version == 1:
                return {self.namespace: []}
            return []

        if search_filter:
            items = jmespath.search(search_filter, items)

        return items
594043
function getAll(appName, callback) {
    var url = format('/%s/apps/%s/domains/', deis.version, appName);
    commons.get(endpoint, callback);
  }