package com.ruoyi.security.service;

/**
 * Authorization service interface
 * Handles user permissions and access control
 */
public interface AuthorizationService {
    
    /**
     * Check if user has permission to access resource
     */
    boolean hasPermission(Long userId, String resource, String action);
    
    /**
     * Check IP whitelist
     */
    boolean isIpAllowed(Long userId, String ipAddress);
    
    /**
     * Apply data masking based on user role
     */
    String maskSensitiveData(String data, String userRole, String fieldType);
    
    /**
     * Get user access level for resource
     */
    String getAccessLevel(Long userId, String resourceType);
    
    /**
     * Check field-level permissions
     */
    boolean canAccessField(Long userId, String fieldName);
}