This is the error I get with the following controller and visual force page:
Error:
Unknown method 'Module_Test2__CM_Components__cStandardController.renderResponse()' Error is in expression '{!renderResponse}' in page module_test2:cmtracknewcomponents2
Controller
public Object firstMethod() {
//Timeout in seconds, 120is limit
Continuation con = new Continuation(120);
// Set callback method
con.continuationMethod = 'renderResponse';
showFilterPanel = false;
showConflictingPanel = false;
filter = '';
// Check if selected metadata is a child object
isChildMetadata = childToParentMetadata.containsKey(metaDataType);
// Instantiate and refill items list
metaDataItemsStatic = new List<MetaDataWrapper>();
Project__c proj = [SELECT Id, Name, TargetOrgId__c, TargetOrgPassword__c, TargetOrgToken__c, TargetOrgUsername__c
FROM Project__c
WHERE Id = :changeRequest.Project__c];
MetadataService.FileProperties[] response = apiService.listMetadataByType(con,metaDataType);
con.state = response;
return con;
}
public Object renderResponse(Object state){
if(state == null){
return null;
}
MetadataService.FileProperties[] filePropertiesStatic = (MetadataService.FileProperties[])state;
// Get already tracked component per selected metadata type
Map<String, Integer> fullNameToTrackedComponent = new Map<String, Integer>();
for (CM_Components__c tracked : [
Select Full_Name__c
From CM_Components__c
Where Included_in__c = : changeRequest.Id
AND Metadata_Type__c = :metaDataType]) {
fullNameToTrackedComponent.put(tracked.Full_Name__c, 1);
}
// Create elements list to display on the page
if (filePropertiesStatic != null) {
Integer counter = 0;
for (MetadataService.FileProperties fileProperty : filePropertiesStatic) {
// Check if already tracked
if (fullNameToTrackedComponent.containsKey(fileProperty.fullName)) {
continue;
}
MetaDataWrapper wrap = new MetaDataWrapper(
counter,
fileProperty.fullName,
fileProperty.fileName,
fileProperty.type_x,
fileProperty.lastModifiedByName,
fileProperty.lastModifiedDate,
isChildMetadata);
metaDataItemsStatic.add(wrap);
counter++;
}
}
// Sort items
metaDataItemsStatic.sort();
// Check items list size
if (metaDataItemsStatic.size() > COLLECTION_SIZE_LIMIT) {
showFilterPanel = true;
ApexPages.addMessage(new ApexPages.Message(ApexPages.Severity.Warning, 'Retrieved list was too long to display on the page! Please provide a filter to limit results'));
while(metaDataItemsStatic.size()>COLLECTION_SIZE_LIMIT){
metaDataItemsStatic.remove(COLLECTION_SIZE_LIMIT);
}
}
return null;
}
Visualforce Page
<apex:page standardController="CM_Components__c" extensions="CMTrackNewComponentControllerExt2" action="{!init}" sidebar="false" >
..........
<apex:pageBlockSectionItem >
<apex:outputLabel value="Metadata Type:" />
<apex:selectList size="1" value="{!MetadataType}" onclick="alertWhenChangingMetadata()">
<apex:selectOptions value="{!MetadataTypes}"/>
<apex:actionSupport event="onchange" action="{!firstMethod}" oncomplete="loadItemsTable()" reRender="itemsTable,msgs,filterPanel" />
</apex:selectList>
</apex:pageBlockSectionItem>
.............................
<!-- Retrieved components table -->
<apex:pageBlockSection id="itemsTable" title="Components Table" collapsible="false" columns="1">
</apex:pageBlockSection>
Why am I getting this error?