// Map maps a rune to a (possibly empty) rune slice via a stringprep Mapping.
// The ok return value is false if the rune was not found.
323984
func (m Mapping) Map(r rune) (replacement []rune, ok bool) {
	rs, ok := m[r]
	if !ok {
		return nil, false
	}
	return rs, true
}
1294365
func Map(tbl *lua.LTable, st interface{}) error {
	return NewMapper(Option{}).Map(tbl, st)
}
141612
func (feature *Feature) Map() map[string]interface{} {
	result := make(map[string]interface{})
	switch ft := feature.Geometry.(type) {
	case Mapper:
		result[GEOMETRY] = ft.Map()
	case map[string]interface{}:
		result[GEOMETRY] = ft
	default:
		result[GEOMETRY] = nil
	}
	result[PROPERTIES] = feature.Properties
	result[TYPE] = FEATURE
	result[ID] = feature.ID
	return result
}
262522
func (mp MultiPolygon) Map() map[string]interface{} {
	result := make(map[string]interface{})
	result[COORDINATES] = mp.Coordinates
	result[TYPE] = MULTIPOLYGON
	return result
}
419161
func (mls MultiLineString) Map() map[string]interface{} {
	result := make(map[string]interface{})
	result[COORDINATES] = mls.Coordinates
	result[TYPE] = MULTILINESTRING
	return result
}
1123444
func Map(args ...cty.Value) (cty.Value, error) {
	return MapFunc.Call(args)
}
207832
func (polygon Polygon) Map() map[string]interface{} {
	result := make(map[string]interface{})
	result[COORDINATES] = polygon.Coordinates
	result[TYPE] = POLYGON
	return result
}
933085
func Map(path string, sz int64) ([]byte, error) {
	fi, err := os.Stat(path)
	if err != nil {
		return nil, err
	}

	// Truncate file to size if too small.
	if fi.Size() < sz {
		if err := os.Truncate(path, sz); err != nil {
			return nil, err
		}
	} else {
		sz = fi.Size()
	}
	if sz == 0 {
		return nil, nil
	}

	f, err := os.Open(path)
	if err != nil {
		return nil, err
	}
	defer f.Close()

	lo, hi := uint32(sz), uint32(sz>>32)
	fmap, err := syscall.CreateFileMapping(syscall.Handle(f.Fd()), nil, syscall.PAGE_READONLY, hi, lo, nil)
	if err != nil {
		return nil, err
	}
	defer syscall.CloseHandle(fmap)

	ptr, err := syscall.MapViewOfFile(fmap, syscall.FILE_MAP_READ, 0, 0, uintptr(sz))
	if err != nil {
		return nil, err
	}
	data := (*[1 << 30]byte)(unsafe.Pointer(ptr))[:sz]

	return data, nil
}
197899
func (m *Model) Map(words []string) map[string]Vector {
	result := make(map[string]Vector)
	for _, w := range words {
		if v, ok := m.words[w]; ok {
			result[w] = v
		}
	}
	return result
}
648027
func (gr *GenericRecord) Map() map[string]interface{} {
	m := make(map[string]interface{})
	for k, v := range gr.fields {
		if r, ok := v.(*GenericRecord); ok {
			v = r.Map()
		}
		if a, ok := v.([]interface{}); ok {
			slice := make([]interface{}, len(a))
			for i, elem := range a {
				if rec, ok := elem.(*GenericRecord); ok {
					elem = rec.Map()
				}
				slice[i] = elem
			}
			v = slice
		}
		m[k] = v
	}
	return m
}
777511
func (f StringsMap) String() string {
	var s []string
	for k := range f {
		s = append(s, k)
	}
	return strings.Join(s, ",")
}
590302
func (e *Entity) Map() map[string]interface{} {
	values := make(map[string]interface{})
	for _, fp := range e.class.getFieldPaths(newFieldPath(), e.state) {
		values[e.class.getNameForFieldPath(fp)] = e.state.get(fp)
	}
	return values
}
433042
func (q QQ) Map(x float64) float64 {
	return q.Dest.Unmap(q.Src.Map(x))
}
1050189
func (members Members) Map(f func(member NetworkMember) NetworkMember) Members {
	var res Members
	for _, m := range members {
		res = append(res, f(m))
	}
	return res
}
1287876
func (r *Request) Map(fn MapRequestFunc) *Request {
	r.Mappers = append(r.Mappers, fn)
	return r
}
944952
func Map(f, input interface{}) interface{} {
	inputValue := reflect.ValueOf(input)
	funcValue := reflect.ValueOf(f)
	_len := inputValue.Len()
	retValue := reflect.MakeSlice(reflect.TypeOf(input), _len, _len)
	for i := 0; i < _len; i++ {
		out := funcValue.Call([]reflect.Value{inputValue.Index(i)})
		retValue.Index(i).Set(out[0])
	}
	return retValue.Interface()
}
1290739
func formatMap(m map[string]string) string {
	var l string
	for key, value := range m {
		l += key + "=" + fmt.Sprintf("%q", value) + "\n"
	}
	return l
}