XML serialization of this list taken to be sitemapindex entries.
550009
def index_as_xml(self):
        """"""
        self.default_capability()
        s = self.new_sitemap()
        return s.resources_as_xml(self, sitemapindex=True)
1068645
def start_output (self):
        """"""
        super(SitemapXmlLogger, self).start_output()
        self.xml_start_output()
        attrs = {u"xmlns": u"http://www.sitemaps.org/schemas/sitemap/0.9"}
        self.xml_starttag(u'urlset', attrs)
        self.flush()
853223
public void createSitemapSubEntry(final CmsClientSitemapEntry newEntry, CmsUUID parentId, String sitemapType) {

        CmsUUID structureId = m_data.getDefaultNewElementInfo().getCopyResourceId();
        newEntry.setResourceTypeName(sitemapType);
        create(newEntry, parentId, m_data.getDefaultNewElementInfo().getId(), structureId, null, true);
    }
1122414
def serialize(self, data):
        
        with open(self.dest, 'wb') as fh:
            root = et.Element('nrml')
            hazard_map = et.SubElement(root, 'hazardMap')
            _set_metadata(hazard_map, self.metadata, _ATTR_MAP)

            for lon, lat, iml in data:
                node = et.SubElement(hazard_map, 'node')
                node.set('lon', str(lon))
                node.set('lat', str(lat))
                node.set('iml', str(iml))

            nrml.write(list(root), fh)
145004
public static String mapXMLToObject(String xml) {
		for (int i = 0; i < keyWordMapping.length; i++) {
			if (keyWordMapping[i][0].equalsIgnoreCase(xml)) {
				return keyWordMapping[i][1];
			}
		}
		return xml;
	}
573168
def to_xml
			result_string = String.new
			result_string << "<results>\n"
			@results.each do |result|
				result_string << "\t<vtresult>\n"
				RESULT_FIELDS.each{|field|
					result_string << "\t\t<#{field.to_s}>#{result[field]}</#{field.to_s}>\n" unless field == :permalink and result['permalink'].nil?
				}
				result_string << "\t</vtresult>\n"
			end if @results != nil
			result_string << "</results>\n"

			result_string
		end
1057189
def _serialize_list(cls, list_):
        

        list_serialized = []

        for item in list_:
            item_serialized = cls.serialize(item)
            list_serialized.append(item_serialized)

        return list_serialized
640108
public Map<String, Object> getSiteProperties()
    {
        Map<String, Object> properties = new HashMap<String, Object>();
        
        Record recUser = this.getMainRecord();
        
        String sitePrefix = ((PropertiesField)recUser.getField(UserInfo.PROPERTIES)).getProperty(MenusMessageData.SITE_PREFIX);
        if (sitePrefix == null)
        {
            sitePrefix = recUser.getField(UserInfo.USER_NAME).toString();
            if (sitePrefix.indexOf('@') != -1)
                sitePrefix = sitePrefix.substring(0, sitePrefix.indexOf('@'));
            sitePrefix = sitePrefix.toLowerCase();
            sitePrefix = sitePrefix.replace('.', '-');
        }
        properties.put(MenusMessageData.SITE_PREFIX, sitePrefix);
        
        String siteTemplate = this.getProperty(SITE_TEMPLATE_CODE_PARAM);
        if (siteTemplate == null)
            siteTemplate = SITE_TEMPLATE_CODE;
        properties.put(SITE_TEMPLATE_CODE_PARAM, siteTemplate);
        
        String homeCode = this.getProperty(MenusMessageData.SITE_HOME_MENU);
        if (homeCode == null)
            homeCode = HOME_MENU_CODE;
        properties.put(MenusMessageData.SITE_HOME_MENU, homeCode);
        
        String siteHomeCode = this.getProperty(MenusMessageData.SITE_TEMPLATE_MENU);
        if (siteHomeCode == null)
            siteHomeCode = DEFAULT_SITE_HOME_CODE;
        properties.put(MenusMessageData.SITE_TEMPLATE_MENU, siteHomeCode);
        
        String processClassName = this.getProperty(RunRemoteProcessMessageData.PROCESS_CLASS_NAME);
        if (processClassName == null)
            processClassName = BaseSetupSiteProcess.class.getName();
        properties.put(RunRemoteProcessMessageData.PROCESS_CLASS_NAME, processClassName);
        
        String destination = this.getProperty(TrxMessageHeader.DESTINATION_PARAM);
        if (destination == null)
            destination = "http://www.tourgeek.com:8181/xmlws";
        properties.put(TrxMessageHeader.DESTINATION_PARAM, destination);        
        
        String userHomeMenu = this.getProperty(ADMIN_HOME_MENU_CODE);
        if (userHomeMenu == null)
            userHomeMenu = DEFAULT_ADMIN_HOME_MENU;
        properties.put(ADMIN_HOME_MENU_CODE, userHomeMenu);
        
        return properties;
    }
582389
public List<LocaleEncodingMappingListType<WebFragmentDescriptor>> getAllLocaleEncodingMappingList()
   {
      List<LocaleEncodingMappingListType<WebFragmentDescriptor>> list = new ArrayList<LocaleEncodingMappingListType<WebFragmentDescriptor>>();
      List<Node> nodeList = model.get("locale-encoding-mapping-list");
      for(Node node: nodeList)
      {
         LocaleEncodingMappingListType<WebFragmentDescriptor>  type = new LocaleEncodingMappingListTypeImpl<WebFragmentDescriptor>(this, "locale-encoding-mapping-list", model, node);
         list.add(type);
      }
      return list;
   }
194215
def serialize(self):
        

        data = {}
        for k, v in self.iteritems():
            if k.startswith('_'):
                continue

            if isinstance(v, APIModel):
                data[k] = v.serialize()
            elif v and is_seq_not_string(v) and isinstance(v[0], APIModel):
                data[k] = [x.serialize() for x in v]
            else:
                data[k] = v

        return data
849974
public function index() {
		$tablesToList = [];
		$data = [];

		if (Configure::check('Sitemap.tables')) {
			$tablesToList = Configure::read('Sitemap.tables');
		}

		foreach ($tablesToList as $table) {
			$tableInstance = $this->loadModel($table);
			$data[$table] = $tableInstance->find('forSitemap');
		}

		$this->set('data', $data);
		$this->set('_serialize', false);
	}
1172077
function createPinDateMapFromRssXmlObject(xmlObject) {
    var pinDateMap;

    try {
        pinDateMap = {};
        var pins = xmlObject.rss.channel[0].item;
        for (var i = 0; i < pins.length; i++) {
            var publishDate = new Date(pins[i].pubDate[0]);
            var pinId = getPinIdFromUrl(pins[i].guid[0]);
            pinDateMap[pinId] = publishDate;
        }
    } catch (e) {
        pinDateMap = {};
    }

    return pinDateMap;
}
937527
def serialize(self, value, entity, request):
        
        value = super(ListField, self).serialize(value, entity, request)
        if value is None:
            return
        ret = []
        for v in value:
            ret.append(self.itemspec.serialize(v, entity, request))
        return ret
179846
private void _serializeList(String name, List list, StringBuilder sb, Set<Object> done) throws ConverterException {

	if (useShortcuts) sb.append("[];");
	else sb.append("new Array();");

	ListIterator it = list.listIterator();
	int index = -1;
	while (it.hasNext()) {
	    // if(index!=-1)sb.append(",");
	    index = it.nextIndex();
	    sb.append(name + "[" + index + "]=");
	    _serialize(name + "[" + index + "]", it.next(), sb, done);
	    // sb.append(";");
	}
    }
122436
function() {
            var sitemap = sm.createSitemap({
                cacheTime: 600000,
                hostname: url.resolve(this.config.get('pluginsConfig.sitemap.hostname'), '/'),
                urls: urls
            });

            var xml = sitemap.toString();

            return this.output.writeFile('sitemap.xml', xml);
        }
845660
def sitemap(request):
    """"""
    xml = Sitemap()
    author = request.matchdict.get('from_id')
    if author is not None:
        match = "AND '{}' = authors[1]".format(author)
    else:
        match = ''

    with db_connect() as db_connection:
        with db_connection.cursor() as cursor:
            cursor.execute("""SELECT
                    ident_hash(uuid, major_version, minor_version)
                        AS idver,
                    name,
                    revised
                FROM latest_modules
                WHERE portal_type NOT IN ('CompositeModule', 'SubCollection')
                {}
                ORDER BY module_ident DESC""".format(match))
            res = cursor.fetchall()
            for ident_hash, page_name, revised in res:
                #  replace punctuation with whitespace
                page_name = re.sub(NON_WORD, ' ',
                                   page_name.decode('utf-8'), re.UNICODE)
                # remove leading and trailing whitespace
                page_name = page_name.strip().encode('utf-8')
                # replace spaces with dashes
                page_name = re.sub(' +', '-',
                                   page_name.decode('utf-8'), re.UNICODE)
                url = request.route_url('content',
                                        ident_hash=ident_hash,
                                        ignore=u'/{}'.format(page_name))
                if notblocked(url):
                    xml.add_url(url, lastmod=revised)

    resp = request.response
    resp.status = '200 OK'
    resp.content_type = 'text/xml'
    resp.body = xml()
    return resp
378559
def toxml(self):
        

        return '<DerivedParameter name="{0}"'.format(self.name) +\
          (' dimension="{0}"'.format(self.dimension) if self.dimension else '') +\
          (' value="{0}"'.format(self.value) if self.value else '') +\
          '/>'