Ejemplo n.º 1
0
        public bool IsResourceSupported(PhactoryHost.Database.Resource resource)
        {
            FileInfo fileInfo = Host.GetFileInfo(resource);

            if (fileInfo == null)
            {
                return(false);
            }

            foreach (PhactoryHost.PluginExtension extension in GetSupportedExtensions())
            {
                if (String.Compare(extension.GetName(), fileInfo.Extension, true) == 0)
                {
                    return(true);
                }
            }

            return(false);
        }
Ejemplo n.º 2
0
        public bool CreateEmptyResource(PhactoryHost.Database.Resource resource)
        {
            File.CreateText(Host.GetFileInfo(resource).FullName).Close();

            return(true);
        }