visualforce 页面显示未知方法错误

visualforce page shows uknown method error

我有 2 个包装纸 class,如下所示

public class Wr_Studennt{
    public string name{get;set;}
    public decimal salary{get;set;}
    public decimal exp{get;set;}
    public string technology{get;set;}
    
}

public class Wr_Address {
    public String city{get;set;}
    public string place{get;set;}
    public string pincode{get;set;}
    public String state{get;set;}
}

我的顶点class如下

public class wr_Student_Address {
    public Wr_Studennt st{set;get;}
     public wr_student_Address()
    {
        st=new Wr_Studennt();
        
           }
    public void setstudent(string name,decimal salary,decimal exp,string technology)
    {
        st.name=name;
        st.salary=salary;
        st.exp=exp;
        st.technology=technology;
        
    }
    
    
}

我的VF页面如下

<apex:page controller="wr_Student_Address">
    <apex:form>
   <apex:pageblock title="Student Details">
    <apex:pageBlockSection>
        
        <apex:outputLabel value="Name: "/>
                    <apex:inputText value="{!name}" />
        <apex:outputLabel value="Salary: "/>
                    <apex:inputText value="{!salary}" />
        <apex:outputLabel value="Exp: "/>
                    <apex:inputText value="{!exp}" />
        <apex:outputLabel value="Technology: "/>
                    <apex:inputText value="{!technology}" />
       
          <apex:commandButton value="setstudent" action="{! setstudent}" />
        
       </apex:pageBlockSection>
    </apex:pageblock>


</apex:form>

</apex:page>

显示

Unknown property 'wr_Student_Address.name' error in line 0.

请帮我解决这个问题。 visualforce 页面显示

unknown method error

您的页面控制器 wr_Student_Address 只有 1 个 属性:st。 class.

中没有直接调用 name 的字段

尝试合并字段 {!st.name}