我正在锻炼骡子我在这里读到
我想尝试这个示例,然后我创建了一个项目并在 Mule Studio 中创建了一个 java 类,之后我复制了这段代码:
package org.mule.module.twilio;
import org.mule.api.annotations.Configurable;
import org.mule.api.annotations.Module;
import org.mule.api.annotations.Processor;
import org.mule.api.annotations.lifecycle.Start;
import org.mule.api.annotations.param.Optional;
import org.mule.api.callback.HttpCallback;
@Module(name = "twilio")
public class TwilioConnector {
/**
* The account sid to be used to connect to Twilio.
*/
@Configurable
private String accountSid;
/**
* The authentication token to be used to connect to Twilio
*/
@Configurable
private String authToken;
private TwilioClient twilioClient;
@Start
public void createTwilioClient() {
twilioClient = new TwilioClient(accountSid, authToken);
}
}
但我有很多错误:所有
The import org.mule.api.annotations.Configurable cannot be resolved
The import org.mule.api.annotations.Module cannot be resolved
The import org.mule.api.annotations.Processor cannot be resolved
The import org.mule.api.annotations.lifecycle cannot be resolved
The import org.mule.api.annotations.param.Optional cannot be resolved
The import org.mule.api.callback cannot be resolved
附近所有注释都不知道所有 clsaa 导入是:Configurable cannot be resolve to a type