First time with this error - Inconsistent Availability

This is my first experience with interfaces and the correct namespace structure. When I compile, I get the error below, I have no idea what that means. Any searches that I look up reveal private public questions, but both are publicly available. Any ideas?

Error Inconsistent availability: the return type "System.Collections.Generic.List" is less accessible than the method "Webtext.ApplicationEntities.Implementations.AdditionalEntities.UrlBuilderO2.GetUrlRequests (string, string, string, string) 'C: \ Users \ Laptop \ documents \ visual studio 2010 \ Projects \ Webtext \ Webtext \ ApplicationEntities \ Implementations \ AdditionalEntities \ UrlBuilderO2.cs 19 39 Web Text

Code Files:

namespace Webtext.ApplicationEntities.Interfaces
{
    interface IUrlBuilder
    {
       List<IOperatorRequest> GetUrlRequests(string UserName, string Password, string MessageRecipient, string Message);
    }
}

and

namespace Webtext.ApplicationEntities.Implementations.AdditionalEntities
{
    public class UrlBuilderO2: IUrlBuilder
    {

        public List<IOperatorRequest> GetUrlRequests(string UserName, string Password, string MessageRecipient, string Message)
        {
            throw new NotImplementedException();
        }
    }
}

Namespace structure

Webtext

ApplicationEntities

     Interfaces
          ##### INTERFACE IS HERE

     Implementations

          AdditionalEntities
               ##### URL BUILDER IS HERE
+3
3

public public, public.
IOperatorRequest public UrlBuilderO2 class GetUrlReuests public.

+7

IOperatorRequest, , internal.

UPDATE

, , . .

, ( , ), , . - , .

+3

IOperatorRequest internal, , public.

Top-level types that are not nested in other types can only have internal or public availability. The default accessibility for these types is internal .

from MSDN

+2
source

Source: https://habr.com/ru/post/1774207/


All Articles