GetShaderPropertyHandler() private static method

private static GetShaderPropertyHandler ( Shader shader, string name ) : MaterialPropertyHandler
shader UnityEngine.Shader
name string
return MaterialPropertyHandler
        internal static MaterialPropertyHandler GetHandler(Shader shader, string name)
        {
            MaterialPropertyHandler result;

            if (shader == null)
            {
                result = null;
            }
            else
            {
                string propertyString = MaterialPropertyHandler.GetPropertyString(shader, name);
                MaterialPropertyHandler materialPropertyHandler;
                if (MaterialPropertyHandler.s_PropertyHandlers.TryGetValue(propertyString, out materialPropertyHandler))
                {
                    result = materialPropertyHandler;
                }
                else
                {
                    materialPropertyHandler = MaterialPropertyHandler.GetShaderPropertyHandler(shader, name);
                    if (materialPropertyHandler != null && materialPropertyHandler.IsEmpty())
                    {
                        materialPropertyHandler = null;
                    }
                    MaterialPropertyHandler.s_PropertyHandlers[propertyString] = materialPropertyHandler;
                    result = materialPropertyHandler;
                }
            }
            return(result);
        }
        internal static MaterialPropertyHandler GetHandler(Shader shader, string name)
        {
            if ((UnityEngine.Object)shader == (UnityEngine.Object)null)
            {
                return((MaterialPropertyHandler)null);
            }
            string propertyString = MaterialPropertyHandler.GetPropertyString(shader, name);
            MaterialPropertyHandler materialPropertyHandler;

            if (MaterialPropertyHandler.s_PropertyHandlers.TryGetValue(propertyString, out materialPropertyHandler))
            {
                return(materialPropertyHandler);
            }
            materialPropertyHandler = MaterialPropertyHandler.GetShaderPropertyHandler(shader, name);
            if (materialPropertyHandler != null && materialPropertyHandler.IsEmpty())
            {
                materialPropertyHandler = (MaterialPropertyHandler)null;
            }
            MaterialPropertyHandler.s_PropertyHandlers[propertyString] = materialPropertyHandler;
            return(materialPropertyHandler);
        }