コード例 #1
0
 /// <summary>
 /// Set phone number types for specified locale.
 /// </summary>
 /// <param name="phoneNumberTypes">Phone number types.</param>
 /// <param name="locale">Locale.</param>
 /// <returns>Phone number types for specified locale.</returns>
 protected override void SetPhoneNumberTypes(PhoneNumberTypeList phoneNumberTypes,
                                             ILocale locale)
 {
     lock (PhoneNumberTypes)
     {
         PhoneNumberTypes[locale.ISOCode] = phoneNumberTypes;
     }
 }
        /// <summary>
        /// Get Phone number types for specified locale.
        /// </summary>
        /// <param name="locale">Locale.</param>
        /// <returns>Phone number types for specified locale.</returns>
        protected virtual PhoneNumberTypeList GetPhoneNumberTypes(ILocale locale)
        {
            PhoneNumberTypeList phoneNumberTypes = null;

            if (PhoneNumberTypes.ContainsKey(locale.ISOCode))
            {
                phoneNumberTypes = (PhoneNumberTypeList)(PhoneNumberTypes[locale.ISOCode]);
            }
            return(phoneNumberTypes);
        }
コード例 #3
0
        /// <summary>
        /// Get Phone number types for specified locale.
        /// </summary>
        /// <param name="locale">Locale.</param>
        /// <returns>Phone number types for specified locale.</returns>
        protected override PhoneNumberTypeList GetPhoneNumberTypes(ILocale locale)
        {
            PhoneNumberTypeList phoneNumberTypes = null;

            lock (PhoneNumberTypes)
            {
                if (PhoneNumberTypes.ContainsKey(locale.ISOCode))
                {
                    phoneNumberTypes = (PhoneNumberTypeList)(PhoneNumberTypes[locale.ISOCode]);
                }
            }
            return(phoneNumberTypes);
        }
 /// <summary>
 /// Set phone number types for specified locale.
 /// </summary>
 /// <param name="phoneNumberTypes">Phone number types.</param>
 /// <param name="locale">Locale.</param>
 protected virtual void SetPhoneNumberTypes(PhoneNumberTypeList phoneNumberTypes,
                                            ILocale locale)
 {
     PhoneNumberTypes[locale.ISOCode] = phoneNumberTypes;
 }