/// <summary> /// Return the service instance if the factory's id is equal to the key's /// currentID. Service is ignored. /// </summary> /// public virtual Object Create(ICUService.Key key, ICUService service) { if (id.Equals(key.CurrentID())) { return(instance); } return(null); }
protected internal bool HandlesKey(ICUService.Key key) { if (key != null) { String id = key.CurrentID(); ILOG.J2CsMapping.Collections.ISet supported = GetSupportedIDs(); return(ILOG.J2CsMapping.Collections.Collections.Contains(id, supported)); } return(false); }
/// <summary> /// Given a visible id, return the display name in the requested locale. If /// there is no directly supported id corresponding to this id, return null. /// </summary> /// public String GetDisplayName(String id_0, ULocale locale) { IDictionary m = GetVisibleIDMap(); ICUService.Factory f = (ICUService.Factory)ILOG.J2CsMapping.Collections.Collections.Get(m, id_0); if (f != null) { return(f.GetDisplayName(id_0, locale)); } ICUService.Key key = CreateKey(id_0); while (key.Fallback()) { f = (ICUService.Factory)ILOG.J2CsMapping.Collections.Collections.Get(m, key.CurrentID()); if (f != null) { return(f.GetDisplayName(id_0, locale)); } } return(null); }